Skip to content

Commit

Permalink
Merge pull request #10660: jewel: multisite segfault on ~RGWRealmWatc…
Browse files Browse the repository at this point in the history
…her if realm was deleted

Reviewed-by: Loic Dachary <ldachary@redhat.com>
  • Loading branch information
Loic Dachary committed Aug 24, 2016
2 parents 3b0429a + 2485efc commit ef60460
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/rgw/rgw_realm_watcher.cc
Expand Up @@ -130,9 +130,12 @@ int RGWRealmWatcher::watch_restart()
<< " with " << cpp_strerror(-r) << dendl;
}
r = pool_ctx.watch2(watch_oid, &watch_handle, this);
if (r < 0)
if (r < 0) {
lderr(cct) << "Failed to restart watch on " << watch_oid
<< " with " << cpp_strerror(-r) << dendl;
pool_ctx.close();
watch_oid.clear();
}
return r;
}

Expand Down

0 comments on commit ef60460

Please sign in to comment.