From 12253367fda3a0f06fc851beadb71dc6748cc330 Mon Sep 17 00:00:00 2001 From: Greg Farnum Date: Mon, 1 Aug 2016 19:38:20 -0700 Subject: [PATCH] mds: fix up _dispatch ref-counting semantics Signed-off-by: Greg Farnum --- src/mds/MDSRank.cc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/mds/MDSRank.cc b/src/mds/MDSRank.cc index ac0fb6c825930..b6e0c1b95dd8f 100644 --- a/src/mds/MDSRank.cc +++ b/src/mds/MDSRank.cc @@ -418,8 +418,8 @@ bool MDSRankDispatcher::ms_dispatch(Message *m) return ret; } -/* If this function returns true, it has put the message. If it returns false, - * it has not put the message. */ +/* If this function returns true, it recognizes the message and has taken the + * reference. If it returns false, it has done neither. */ bool MDSRank::_dispatch(Message *m, bool new_msg) { if (is_stale_message(m)) { @@ -436,7 +436,6 @@ bool MDSRank::_dispatch(Message *m, bool new_msg) } else { if (!handle_deferrable_message(m)) { dout(0) << "unrecognized message " << *m << dendl; - m->put(); return false; } } -- 2.39.5