From 5d1c0bf64f34dc4e4fc29e1f5c1664dd9f08abfd Mon Sep 17 00:00:00 2001 From: mmiozzo Date: Thu, 13 Dec 2012 18:44:34 +0100 Subject: [PATCH] Bug-fix LteUeMac:DoReceiveLteControlMessage erroneous NotifyTxOpportunity --- src/lte/model/lte-ue-mac.cc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/lte/model/lte-ue-mac.cc b/src/lte/model/lte-ue-mac.cc index e97df2528..5a8686bb1 100644 --- a/src/lte/model/lte-ue-mac.cc +++ b/src/lte/model/lte-ue-mac.cc @@ -580,11 +580,10 @@ LteUeMac::DoReceiveLteControlMessage (Ptr msg) } else if ((*itBsr).second.txQueueSize > 0) { - bytesForThisLc -= 2; // remove RLC header (*it).second.macSapUser->NotifyTxOpportunity (bytesForThisLc, 0, 0); - if ((*itBsr).second.txQueueSize >= bytesForThisLc) + if ((*itBsr).second.txQueueSize >= bytesForThisLc - 2) { - (*itBsr).second.txQueueSize -= bytesForThisLc; + (*itBsr).second.txQueueSize -= bytesForThisLc - 2; } else {