]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph-objectstore-tool: Fix pgid scan to skip snapdirs
authorDavid Zafman <dzafman@redhat.com>
Fri, 13 Mar 2015 07:41:39 +0000 (00:41 -0700)
committerDavid Zafman <dzafman@redhat.com>
Wed, 13 May 2015 20:09:12 +0000 (13:09 -0700)
Long standing bug where it wasn't skipping snapdirs if !debug
For debug output use stderr like all other cases

Signed-off-by: David Zafman <dzafman@redhat.com>
src/tools/ceph_objectstore_tool.cc

index 7d66c6d46e75bab569b168285734887c28e60d6f..9e43a1540ae1593c348ab86afc3f85e3262a8954 100644 (file)
@@ -2903,8 +2903,9 @@ int main(int argc, char **argv)
     if (op != "list-pgs" && tmppgid != pgid) {
       continue;
     }
-    if (snap != CEPH_NOSNAP && debug) {
-      cout << "skipping snapped dir " << *it
+    if (snap != CEPH_NOSNAP) {
+      if (debug)
+        cerr << "skipping snapped dir " << *it
               << " (pg " << pgid << " snap " << snap << ")" << std::endl;
       continue;
     }