fs: Fix '<' comparison of value produced by logical not '!'

Commit da665fbd introduced the following condition to virLXCProcessEnsureRootFS
and openvzReadFSConf:

if (!(<some_var> = virDomainFSDefNew()) < 0)

which broke the build on fedora with GCC 5.3.1: "logical not is only applied to
the left hand side of comparison".

Signed-off-by: Erik Skultety <eskultet@redhat.com>
This commit is contained in:
Erik Skultety 2016-07-19 09:27:32 +02:00
parent fc624d86ea
commit 28e191a96c
2 changed files with 2 additions and 2 deletions

View File

@ -1153,7 +1153,7 @@ virLXCProcessEnsureRootFS(virDomainObjPtr vm)
if (root)
return 0;
if (!(root = virDomainFSDefNew()) < 0)
if (!(root = virDomainFSDefNew()))
goto error;
root->type = VIR_DOMAIN_FS_TYPE_MOUNT;

View File

@ -351,7 +351,7 @@ openvzReadFSConf(virDomainDefPtr def,
veid);
goto error;
} else if (ret > 0) {
if (!(fs = virDomainFSDefNew()) < 0)
if (!(fs = virDomainFSDefNew()))
goto error;
fs->type = VIR_DOMAIN_FS_TYPE_TEMPLATE;