diff --git a/src/wifi/model/ideal-wifi-manager.cc b/src/wifi/model/ideal-wifi-manager.cc index 87a16752c..f940e8136 100644 --- a/src/wifi/model/ideal-wifi-manager.cc +++ b/src/wifi/model/ideal-wifi-manager.cc @@ -123,7 +123,7 @@ IdealWifiManager::DoInitialize () nModes = GetPhy ()->GetNMcs (); for (uint8_t i = 0; i < nModes; i++) { - for (uint16_t j = 20; j <= GetPhy ()->GetChannelWidth (); j *= 2) + for (uint8_t j = 20; j <= GetPhy ()->GetChannelWidth (); j *= 2) { txVector.SetChannelWidth (j); mode = GetPhy ()->GetMcs (i); @@ -166,6 +166,10 @@ IdealWifiManager::DoInitialize () AddSnrThreshold (txVector, GetPhy ()->CalculateSnr (txVector, m_ber)); } } + if (j == 160) + { + break; + } } } }