From 0ac7f2f6c87e0d454466927b8528b3f3dae812a2 Mon Sep 17 00:00:00 2001 From: Joao Eduardo Luis Date: Wed, 2 Nov 2016 15:33:52 +0000 Subject: [PATCH] mon: MonmapMonitor: return success when monitor will be removed Fixes: http://tracker.ceph.com/issues/17725 Signed-off-by: Joao Eduardo Luis (cherry picked from commit c9d46cfbf2512bc3495c6901de2b8f711bef9bae) Conflicts: src/mon/MonmapMonitor.cc (just inserted the "err = 0" assignment immediately after the error message line) --- src/mon/MonmapMonitor.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mon/MonmapMonitor.cc b/src/mon/MonmapMonitor.cc index c6b21cb47fc7c..05d744244bd0b 100644 --- a/src/mon/MonmapMonitor.cc +++ b/src/mon/MonmapMonitor.cc @@ -373,6 +373,7 @@ bool MonmapMonitor::prepare_command(MMonCommand *m) pending_map.remove(name); pending_map.last_changed = ceph_clock_now(g_ceph_context); ss << "removed mon." << name << " at " << addr << ", there are now " << pending_map.size() << " monitors" ; + err = 0; getline(ss, rs); // send reply immediately in case we get removed mon->reply_command(m, 0, rs, get_last_committed()); -- 2.39.5