]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph-objectstore-tool: Create section around log/missing/divergent_priors of --op log
authorDavid Zafman <dzafman@redhat.com>
Wed, 15 Apr 2015 22:40:41 +0000 (15:40 -0700)
committerDavid Zafman <dzafman@redhat.com>
Wed, 13 May 2015 20:09:13 +0000 (13:09 -0700)
Remove extra new lines in the output

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

index 1f3bc34e258e2416a9f35d42c946c399f4efb66a..8bac5a75324dda46bbfd4827557b9407fe046bee 100644 (file)
@@ -3255,16 +3255,15 @@ int main(int argc, char **argv)
       if (ret > 0)
           goto out;
 
+      formatter->open_object_section("op_log");
       formatter->open_object_section("pg_log_t");
       log.dump(formatter);
       formatter->close_section();
       formatter->flush(cout);
-      cout << std::endl;
       formatter->open_object_section("pg_missing_t");
       missing.dump(formatter);
       formatter->close_section();
       formatter->flush(cout);
-      cout << std::endl;
       formatter->open_object_section("map");
       formatter->open_array_section("divergent_priors");
       for (map<eversion_t, hobject_t>::iterator it = divergent_priors.begin();
@@ -3276,8 +3275,8 @@ int main(int argc, char **argv)
       }
       formatter->close_section();
       formatter->close_section();
+      formatter->close_section();
       formatter->flush(cout);
-      cout << std::endl;
     } else if (op == "rm-past-intervals") {
       ObjectStore::Transaction tran;
       ObjectStore::Transaction *t = &tran;