]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
osd: update for mon_command void change
authorJohn Spray <john.spray@redhat.com>
Wed, 1 Mar 2017 15:21:51 +0000 (15:21 +0000)
committerJohn Spray <john.spray@redhat.com>
Thu, 9 Mar 2017 13:30:07 +0000 (13:30 +0000)
Signed-off-by: John Spray <john.spray@redhat.com>
src/osd/OSD.cc

index e2135a0902c2ec3f03eb7a8dc4e74b9a72be11de..48b73bf50553a0ff1de34f8333295f0682bf63cc 100644 (file)
@@ -3039,9 +3039,8 @@ int OSD::update_crush_location()
     bufferlist inbl;
     C_SaferCond w;
     string outs;
-    int r = monc->start_mon_command(vcmd, inbl, NULL, &outs, &w);
-    if (r == 0)
-      r = w.wait();
+    monc->start_mon_command(vcmd, inbl, NULL, &outs, &w);
+    int r = w.wait();
     if (r < 0) {
       if (r == -ENOENT && !created) {
        string newcmd = "{\"prefix\": \"osd create\", \"id\": " + stringify(whoami)
@@ -3050,9 +3049,8 @@ int OSD::update_crush_location()
        bufferlist inbl;
        C_SaferCond w;
        string outs;
-       int r = monc->start_mon_command(vnewcmd, inbl, NULL, &outs, &w);
-       if (r == 0)
-         r = w.wait();
+       monc->start_mon_command(vnewcmd, inbl, NULL, &outs, &w);
+       int r = w.wait();
        if (r < 0) {
          derr << __func__ << " fail: osd does not exist and created failed: "
               << cpp_strerror(r) << dendl;