From d8606b14dc68ec1fd0c2ecbcb5885ed2b0135d54 Mon Sep 17 00:00:00 2001 From: Radoslaw Zarzynski Date: Fri, 23 Jun 2017 05:09:14 -0400 Subject: [PATCH] rgw: fix segfault in RevokeThread during its shutdown procedure. Fixes: http://tracker.ceph.com/issues/19831 Signed-off-by: Radoslaw Zarzynski Signed-off-by: Radoslaw Zarzynski --- src/rgw/rgw_keystone.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/rgw/rgw_keystone.h b/src/rgw/rgw_keystone.h index df5650c5927..3add9ae8a4c 100644 --- a/src/rgw/rgw_keystone.h +++ b/src/rgw/rgw_keystone.h @@ -12,6 +12,7 @@ #include "rgw_common.h" #include "rgw_http_client.h" #include "common/Cond.h" +#include "global/global_init.h" #include @@ -224,7 +225,7 @@ class TokenCache { friend class TokenCache; typedef RGWPostHTTPData RGWGetRevokedTokens; - CephContext * const cct; + CephContext* const cct; TokenCache* const cache; const rgw::keystone::Config& config; @@ -239,12 +240,13 @@ class TokenCache { config(config), lock("rgw::keystone::TokenCache::RevokeThread") { } + void *entry() override; void stop(); int check_revoked(); } revocator; - CephContext * const cct; + const boost::intrusive_ptr cct; std::string admin_token_id; std::string barbican_token_id; -- 2.39.5