]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
osd: silence gcc -Wparentheses warning 4534/head
authorKefu Chai <kchai@redhat.com>
Mon, 4 May 2015 06:45:11 +0000 (14:45 +0800)
committerKefu Chai <kchai@redhat.com>
Mon, 4 May 2015 13:49:02 +0000 (21:49 +0800)
otherwise we have following warning:
warning: suggest parentheses around operand of ‘!’ or change ‘|’ to
‘||’ or ‘!’ to ‘~’ [-Wparentheses]

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/osd/OSD.cc

index 79078fe69dc57071613b2009978c348e7806a289..ade19f0f24c9491ff83e7d739f1ab6d02e543317 100644 (file)
@@ -2401,8 +2401,7 @@ void OSD::write_superblock(ObjectStore::Transaction& t)
   dout(10) << "write_superblock " << superblock << dendl;
 
   //hack: at minimum it's using the baseline feature set
-  if (!superblock.compat_features.incompat.mask |
-      CEPH_OSD_FEATURE_INCOMPAT_BASE.id)
+  if (!superblock.compat_features.incompat.contains(CEPH_OSD_FEATURE_INCOMPAT_BASE))
     superblock.compat_features.incompat.insert(CEPH_OSD_FEATURE_INCOMPAT_BASE);
 
   bufferlist bl;