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:
John Ferlan 2014-03-14 06:26:40 -04:00
parent c8d6cd853f
commit 759ca3192f
1 changed files with 2 additions and 1 deletions

View File

@ -2239,6 +2239,7 @@ static virDriver openvzDriver = {
};
int openvzRegister(void) {
virRegisterDriver(&openvzDriver);
if (virRegisterDriver(&openvzDriver) < 0)
return -1;
return 0;
}