From 8c85553357d4f2a76a59176dac0104ac6389aa63 Mon Sep 17 00:00:00 2001 From: Jianpeng Ma Date: Thu, 3 Jan 2019 14:34:43 +0800 Subject: [PATCH] ceph_argparse: make command ceph acceph SIGINT. If no --connect-timeout point and there is no ceph.conf, the command 'ceph -s' can't stop by ctrl+c. This introduced by commit 4d8fc26c8 Signed-off-by: Jianpeng Ma --- src/pybind/ceph_argparse.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pybind/ceph_argparse.py b/src/pybind/ceph_argparse.py index af51b39f31b8a..26c24f275123d 100644 --- a/src/pybind/ceph_argparse.py +++ b/src/pybind/ceph_argparse.py @@ -1287,7 +1287,7 @@ class RadosThread(threading.Thread): def run_in_thread(func, *args, **kwargs): interrupt = False timeout = kwargs.pop('timeout', 0) - if timeout == 0: + if timeout == 0 or timeout == None: # python threading module will just get blocked if timeout is `None`, # otherwise it will keep polling until timeout or thread stops. timeout = 2 ** 32 -- 2.39.5