]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
common/ceph_context: avoid unnecessary wait during service thread shutdown 30947/head
authorJason Dillaman <dillaman@redhat.com>
Tue, 15 Oct 2019 22:19:15 +0000 (18:19 -0400)
committerJason Dillaman <dillaman@redhat.com>
Tue, 15 Oct 2019 22:19:15 +0000 (18:19 -0400)
Fixes: https://tracker.ceph.com/issues/42332
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
src/common/ceph_context.cc

index a03b61c69d1c1cb04508ed1a62e5b11ef3fb33f0..17c45e51edbb04c17dd13d49f5a8e46af82df25b 100644 (file)
@@ -197,6 +197,9 @@ public:
   {
     while (1) {
       std::unique_lock l(_lock);
+      if (_exit_thread) {
+        break;
+      }
 
       if (_cct->_conf->heartbeat_interval) {
         auto interval = ceph::make_timespan(_cct->_conf->heartbeat_interval);