From: Yehuda Sadeh Date: Sun, 17 Apr 2016 00:27:35 +0000 (-0700) Subject: rgw: stop cr manager in destructor X-Git-Tag: v10.2.0~1^2~4 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=fe0f4bb59647a0d34a67c254288ac550ed8497d3;p=ceph.git rgw: stop cr manager in destructor callers don't need to call it explicitly Signed-off-by: Yehuda Sadeh --- diff --git a/src/rgw/rgw_coroutine.h b/src/rgw/rgw_coroutine.h index 09128576bb1a..b27d3e74a461 100644 --- a/src/rgw/rgw_coroutine.h +++ b/src/rgw/rgw_coroutine.h @@ -536,6 +536,7 @@ public: } } virtual ~RGWCoroutinesManager() { + stop(); completion_mgr->put(); if (cr_registry) { cr_registry->remove(this); @@ -545,8 +546,9 @@ public: int run(list& ops); int run(RGWCoroutine *op); void stop() { - going_down.set(1); - completion_mgr->go_down(); + if (going_down.inc() == 1) { + completion_mgr->go_down(); + } } virtual void report_error(RGWCoroutinesStack *op);