mirror of
https://github.com/ceph/ceph
synced 2025-01-20 01:51:34 +00:00
librados: watch_flush() on shutdown
Users can easily forget this. It makes shutdown potentially block, but if
they have racing callbacks they get what they ask for.
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 30678f6daf
)
This commit is contained in:
parent
7de1b4d4ff
commit
93825bf05a
@ -282,6 +282,9 @@ int librados::RadosClient::connect()
|
||||
|
||||
void librados::RadosClient::shutdown()
|
||||
{
|
||||
// make sure watch callbacks are flushed
|
||||
watch_flush();
|
||||
|
||||
lock.Lock();
|
||||
if (state == DISCONNECTED) {
|
||||
lock.Unlock();
|
||||
|
Loading…
Reference in New Issue
Block a user