]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
msgr: should be destroyed in the same thread it's created
authorGreg Farnum <gregf@hq.newdream.net>
Thu, 7 Jan 2010 23:35:26 +0000 (15:35 -0800)
committerGreg Farnum <gregf@hq.newdream.net>
Thu, 7 Jan 2010 23:35:26 +0000 (15:35 -0800)
src/client/Client.cc
src/cmon.cc
src/cosd.cc
src/mon/Monitor.cc
src/osd/OSD.cc

index 513bf0e60554a25a59f325f3981c7e3dd5cec33b..6b124952a0cd40db518fbf6b34749d65a04f7db2 100644 (file)
@@ -173,8 +173,6 @@ Client::~Client()
   if (osdmap) { delete osdmap; osdmap = 0; }
   if (mdsmap) { delete mdsmap; mdsmap = 0; }
 
-  if (messenger)
-    messenger->destroy();
 }
 
 
index 68234740001f4ca070125c96f9aeb2a6397ab839..883207cdfe3eb4f9a9c777a152a178228da82f11 100644 (file)
@@ -157,6 +157,7 @@ int main(int argc, const char **argv)
 
   store.umount();
   delete mon;
+  rank->destroy();
 
   // cd on exit, so that gmon.out (if any) goes into a separate directory for each node.
   char s[20];
index 62112710796c37ce2de58634dd6dc4d71e89635a..aacd93d9ac1a8d71e50272aeaa39d3796551c5a8 100644 (file)
@@ -178,9 +178,10 @@ int main(int argc, const char **argv)
 
   rank->wait();
   rank_hb->wait();
-
   // done
   delete osd;
+  rank->destroy();
+  rank_hb->destroy();
 
   // cd on exit, so that gmon.out (if any) goes into a separate directory for each node.
   char s[20];
index 5ac53ccd26a89b9e657a4ab19674e6d046483315..8913afba18f9ec961cb7d0837508d109392a6785 100644 (file)
@@ -111,8 +111,6 @@ Monitor::~Monitor()
     delete *p;
   for (vector<Paxos*>::iterator p = paxos.begin(); p != paxos.end(); p++)
     delete *p;
-  if (messenger)
-    messenger->destroy();
 }
 
 void Monitor::init()
index 8236fb0e197751f6dba007e1a5e80f2740e7193d..047494abbfe63a210476809fd9e023a35f74c4ef 100644 (file)
@@ -292,10 +292,6 @@ OSD::~OSD()
   delete osdmap;
   delete logger;
   delete store;
-  if (messenger)
-    messenger->destroy();
-  if (heartbeat_messenger)
-    heartbeat_messenger->destroy();
 }
 
 bool got_sigterm = false;