wifi: Ensure ADDBA Request frame is queued

This commit is contained in:
Stefano Avallone
2022-03-15 16:57:26 +01:00
parent f3c2163658
commit 815942a5cc

View File

@@ -185,7 +185,12 @@ HtFrameExchangeManager::SendAddBaRequest (Mac48Address dest, uint8_t tid, uint16
txParams.m_acknowledgment = GetAckManager ()->TryAddMpdu (mpdu, txParams);
// Push the MPDU to the front of the queue and transmit it
m_mac->GetQosTxop (tid)->GetWifiMacQueue ()->PushFront (mpdu);
auto queue = m_mac->GetQosTxop (tid)->GetWifiMacQueue ();
if (!queue->PushFront (mpdu))
{
NS_LOG_DEBUG ("Queue is full, replace the oldest frame with the ADDBA Request frame");
queue->Replace (queue->Peek (), mpdu);
}
SendMpduWithProtection (mpdu, txParams);
}