From 30389dc59fb4a237f8091887551e3835ce5f0a99 Mon Sep 17 00:00:00 2001 From: Greg Farnum Date: Tue, 30 Mar 2010 13:58:31 -0700 Subject: [PATCH] msg: fix uses of MMonCommand destructor to use put() --- src/mds/MDS.cc | 2 +- src/mon/Monitor.cc | 2 +- src/osd/OSD.cc | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/mds/MDS.cc b/src/mds/MDS.cc index bf66fbe4e4783..d13a811d8647e 100644 --- a/src/mds/MDS.cc +++ b/src/mds/MDS.cc @@ -643,7 +643,7 @@ void MDS::handle_command(MMonCommand *m) dout(20) << "try_eval(" << inum << ", " << mask << ")" << dendl; } else dout(15) << "inode " << inum << " not in mdcache!" << dendl; } else dout(0) << "unrecognized command! " << m->cmd << dendl; - delete m; + m->put(); } void MDS::handle_mds_map(MMDSMap *m) diff --git a/src/mon/Monitor.cc b/src/mon/Monitor.cc index 21ac3521db484..cfffbf912a3cc 100644 --- a/src/mon/Monitor.cc +++ b/src/mon/Monitor.cc @@ -332,7 +332,7 @@ void Monitor::reply_command(MMonCommand *m, int rc, const string &rs, bufferlist MMonCommandAck *reply = new MMonCommandAck(m->cmd, rc, rs, version); reply->set_data(rdata); send_reply(m, reply); - delete m; + m->put(); } diff --git a/src/osd/OSD.cc b/src/osd/OSD.cc index 20950f212beff..dbb6e4cd0c35d 100644 --- a/src/osd/OSD.cc +++ b/src/osd/OSD.cc @@ -1546,7 +1546,7 @@ void OSD::handle_command(MMonCommand *m) parse_config_option_string(m->cmd[1]); else dout(0) << "unrecognized command! " << m->cmd << dendl; - delete m; + m->put(); } -- 2.39.5