make sure that the mac low listener is destroyed _after_ the mac low itself.
authorMathieu Lacage <mathieu.lacage@sophia.inria.fr>
Wed, 28 May 2008 13:59:53 -0700
changeset 3169 2598ea90f9db
parent 3168 c7d239e85b64
child 3170 d3438b415a8c
make sure that the mac low listener is destroyed _after_ the mac low itself.
src/devices/wifi/dca-txop.cc
--- a/src/devices/wifi/dca-txop.cc	Wed May 28 13:22:50 2008 -0700
+++ b/src/devices/wifi/dca-txop.cc	Wed May 28 13:59:53 2008 -0700
@@ -139,10 +139,6 @@
 DcaTxop::DoDispose (void)
 {
   NS_LOG_FUNCTION (this);
-  delete m_transmissionListener;
-  delete m_dcf;
-  delete m_rng;
-  delete m_txMiddle;
   m_transmissionListener = 0;
   m_dcf = 0;
   m_rng = 0;
@@ -150,6 +146,10 @@
   m_queue = 0;
   m_low = 0;
   m_stationManager = 0;
+  delete m_transmissionListener;
+  delete m_dcf;
+  delete m_rng;
+  delete m_txMiddle;
 }
 
 void