mirror of https://gitee.com/openkylin/libvirt.git
openvzRegister: Check for error return
A recent change to openvz_driver.c caused Coverity to make additional comparisons and find that the openvzRegister() was not checking the status of virRegisterDriver() call like other callers and thus generated a CHECKED_RETURN condition
This commit is contained in:
parent
c8d6cd853f
commit
759ca3192f
|
@ -2239,6 +2239,7 @@ static virDriver openvzDriver = {
|
|||
};
|
||||
|
||||
int openvzRegister(void) {
|
||||
virRegisterDriver(&openvzDriver);
|
||||
if (virRegisterDriver(&openvzDriver) < 0)
|
||||
return -1;
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue