]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
Test: fixing a compile warning in ceph_objectstore_tool.cc
authorZhiqiang Wang <wonzhq@hotmail.com>
Fri, 29 Aug 2014 08:39:40 +0000 (16:39 +0800)
committerDavid Zafman <dzafman@redhat.com>
Tue, 3 Mar 2015 17:51:30 +0000 (09:51 -0800)
For the compiler's sake:
tools/ceph_objectstore_tool.cc:2547:15: warning: â€˜r’ may be used
uninitialized in this function [-Wmaybe-uninitialized]

Signed-off-by: Zhiqiang Wang <wonzhq@hotmail.com>
(cherry picked from commit c3e1466b46076f133b62f98e2c0b712bdde0e119)

src/tools/ceph_objectstore_tool.cc

index ee32c0d28cebaf66eadf18eae3eb959b59c96590..0d0a07b68bce17b477f4fe6f3eea873ceba29611 100644 (file)
@@ -2149,7 +2149,7 @@ int main(int argc, char **argv)
   if (op == "list-lost" || op == "fix-lost") {
     unsigned LIST_AT_A_TIME = 100;
     unsigned scanned = 0;
-    int r;
+    int r = 0;
     vector<coll_t> colls_to_check;
     if (pgidstr.length()) {
       colls_to_check.push_back(coll_t(pgid));