From e770997d0943519bb99b18b1dd0dc680f69c86ca Mon Sep 17 00:00:00 2001 From: Mathieu Lacage Date: Wed, 17 Oct 2007 17:01:51 +0200 Subject: [PATCH] do not call Unref directly anymore. --- src/devices/wifi/wifi-phy.cc | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/devices/wifi/wifi-phy.cc b/src/devices/wifi/wifi-phy.cc index d100b066f..3df3fb71f 100644 --- a/src/devices/wifi/wifi-phy.cc +++ b/src/devices/wifi/wifi-phy.cc @@ -88,7 +88,9 @@ public: m_refCount (1) {} ~RxEvent () - {} + { + NS_ASSERT (m_refCount == 0); + } void Ref (void) const { m_refCount++; @@ -277,7 +279,6 @@ WifiPhy::ReceivePacket (Packet const packet, break; } - event->Unref (); return; maybeCcaBusy: @@ -311,7 +312,6 @@ WifiPhy::ReceivePacket (Packet const packet, } } - event->Unref (); } void WifiPhy::SendPacket (Packet const packet, WifiMode txMode, WifiPreamble preamble, uint8_t txPower) @@ -1173,7 +1173,6 @@ WifiPhy::EndSync (Packet const packet, Ptr event) SwitchFromSync (); m_syncErrorCallback (packet, snr); } - event->Unref (); }