]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
tool/ceph: print return code when json_command failed 15378/head
authorliuchang0812 <liuchang0812@gmail.com>
Wed, 31 May 2017 07:34:25 +0000 (15:34 +0800)
committerliuchang0812 <liuchang0812@gmail.com>
Tue, 6 Jun 2017 12:55:12 +0000 (20:55 +0800)
Signed-off-by: liuchang0812 <liuchang0812@gmail.com>
src/ceph.in

index cf78d5d343ba0cdd25154bdb2be0e3256bed9a6a..e02b8e5dd7d658982f2cde88b01deebb2c3692cb 100755 (executable)
@@ -363,9 +363,9 @@ def do_extended_help(parser, args, target, partial):
                                          prefix='get_command_descriptions',
                                          timeout=10)
         if ret:
-            print("couldn't get command descriptions for {0}: {1}".
-                  format(target, outs), file=sys.stderr)
-            return 1
+            print("couldn't get command descriptions for {0}: {1} ({2})".
+                  format(target, outs, ret), file=sys.stderr)
+            return ret
         else:
             return help_for_sigs(outbuf.decode('utf-8'), partial)