From: Danny Al-Gaaf Date: Tue, 26 Feb 2013 18:51:03 +0000 (+0100) Subject: CephBroker.cc: fix condition X-Git-Tag: v0.59~95^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F76%2Fhead;p=ceph.git CephBroker.cc: fix condition from cppcheck: Fix Suspicious condition (assignment + comparison); Clarify expression with parentheses. Signed-off-by: Danny Al-Gaaf --- diff --git a/src/client/hypertable/CephBroker.cc b/src/client/hypertable/CephBroker.cc index 96fd4830ec21..a6cf6da1daac 100644 --- a/src/client/hypertable/CephBroker.cc +++ b/src/client/hypertable/CephBroker.cc @@ -386,7 +386,7 @@ int CephBroker::rmdir_recursive(const char *directory) { struct dirent de; struct stat st; int r; - if ((r = ceph_opendir(cmount, directory, &dirp) < 0)) + if ((r = ceph_opendir(cmount, directory, &dirp)) < 0) return r; //failed to open while ((r = ceph_readdirplus_r(cmount, dirp, &de, &st, 0)) > 0) { String new_dir = de.d_name;