mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-31 18:15:25 +00:00
vbox: don't register NULL driver
We were missing check for the fact that the storage driver was found and in case there is no vbox storage driver available, daemon raised the following error each start: error : virRegisterStorageDriver:592 : driver in virRegisterStorageDriver must not be NULL Fixing this makes the condition unified with networkDriver registration in vbox as well. Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
This commit is contained in:
parent
11a48758a7
commit
55bbc34218
@ -74,7 +74,7 @@ int vboxStorageRegister(void)
|
||||
if (VBoxCGlueInit(&uVersion) == 0)
|
||||
storageDriver = vboxGetStorageDriver(uVersion);
|
||||
|
||||
if (virRegisterStorageDriver(storageDriver) < 0)
|
||||
if (storageDriver && virRegisterStorageDriver(storageDriver) < 0)
|
||||
return -1;
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user