From df81efb5f0198f3fce3a0a0be9704508d7b9a29e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Deronne?= Date: Wed, 9 Mar 2016 21:44:36 +0100 Subject: [PATCH] wifi: (fixes #2332) fix buggy behaviour since commit 96b721d35158 --- RELEASE_NOTES | 1 + src/wifi/model/mac-low.cc | 12 ++++++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/RELEASE_NOTES b/RELEASE_NOTES index 82717bb16..8382c7e77 100644 --- a/RELEASE_NOTES +++ b/RELEASE_NOTES @@ -127,6 +127,7 @@ Bugs fixed - Bug 2321 - Wifi rate managers should not be triggered for each MPDU when A-MPDU is used - Bug 2327 - CWmin value selection for 802.11g is not compliant with the standard rules - Bug 2328 - changes to antenna configuration should update HT MCS set +- Bug 2332 - Assert failed when using aggregation and two pairs of AP-STA Known issues ------------ diff --git a/src/wifi/model/mac-low.cc b/src/wifi/model/mac-low.cc index a21e2afa5..5a9229bdf 100644 --- a/src/wifi/model/mac-low.cc +++ b/src/wifi/model/mac-low.cc @@ -846,8 +846,16 @@ MacLow::ReceiveError (Ptr packet, double rxSnr, bool isEndOfFrame) if (isEndOfFrame == true && m_receivedAtLeastOneMpdu == true) { WifiMacHeader hdr; - MpduAggregator::DeaggregatedMpdus mpdu = MpduAggregator::Deaggregate (packet); - mpdu.begin ()->first->PeekHeader (hdr); + AmpduTag ampdu; + if (packet->RemovePacketTag (ampdu)) + { + MpduAggregator::DeaggregatedMpdus mpdu = MpduAggregator::Deaggregate (packet); + mpdu.begin ()->first->PeekHeader (hdr); + } + else + { + packet->PeekHeader (hdr); + } if (hdr.GetAddr1 () != m_self) { NS_LOG_DEBUG ("hdr addr1 " << hdr.GetAddr1 () << "not for me (" << m_self << "); returning");