fix compilation warnings in optimized mode

This commit is contained in:
Nicola Baldo
2013-01-08 12:57:51 +01:00
parent 59400fdb59
commit de78d418b4
3 changed files with 10 additions and 10 deletions

View File

@@ -990,7 +990,7 @@ uint64_t
FindImsiForEnb (std::string path, uint16_t rnti)
{
NS_LOG_FUNCTION (path << rnti);
uint64_t imsi;
uint64_t imsi = 0;
if (path.find ("/DlPhyTransmission"))
{
// /NodeList/0/DeviceList/0/LteEnbPhy/DlPhyTransmission/LteEnbRrc/UeMap/1
@@ -1001,7 +1001,7 @@ FindImsiForEnb (std::string path, uint16_t rnti)
imsi = FindImsiFromEnbRlcPath (p);
NS_LOG_LOGIC ("FindImsiForEnb[Tx]: " << path << ", " << rnti << ", " << imsi);
}
else if (path.find ("/UIlPhyReception"))
else if (path.find ("/UlPhyReception"))
{
std::string p = path.substr (0, path.find ("/LteUePhy"));
imsi = FindImsiFromLteNetDevice (p);
@@ -1015,14 +1015,14 @@ uint64_t
FindImsiForUe (std::string path, uint16_t rnti)
{
NS_LOG_FUNCTION (path << rnti);
uint64_t imsi;
if (path.find ("/UIlPhyTransmission"))
uint64_t imsi = 0;
if (path.find ("/UlPhyTransmission"))
{
std::string p = path.substr (0, path.find ("/LteUePhy"));
imsi = FindImsiFromLteNetDevice (p);
NS_LOG_LOGIC ("FindImsiForUe[Tx]: " << path << ", " << rnti << ", " << imsi);
}
else if (path.find ("/DIlPhyReception"))
else if (path.find ("/DlPhyReception"))
{
// /NodeList/0/DeviceList/0/LteEnbPhy/LteSpectrumPhy
std::ostringstream oss;

View File

@@ -474,14 +474,11 @@ LteEnbMac::DoSubframeIndication (uint32_t frameNo, uint32_t subframeNo)
// process received RACH preambles and notify the scheduler
FfMacSchedSapProvider::SchedDlRachInfoReqParameters rachInfoReqParams;
NS_ASSERT (subframeNo > 0 && subframeNo <= 10); // subframe in 1..10
// see TS 36.321 5.1.4; preambles were sent two frames ago
// (plus 3GPP counts subframes from 0, not 1)
uint16_t raRnti = subframeNo - 3;
for (std::map<uint8_t, uint32_t>::const_iterator it = m_receivedRachPreambleCount.begin ();
it != m_receivedRachPreambleCount.end ();
++it)
{
NS_LOG_INFO ("RA-RNTI " << raRnti << ", preambleId " << (uint32_t) it->first << ": " << it->second << " received");
NS_LOG_INFO (this << " preambleId " << (uint32_t) it->first << ": " << it->second << " received");
NS_ASSERT (it->second != 0);
if (it->second > 1)
{
@@ -1026,8 +1023,10 @@ LteEnbMac::DoSchedDlConfigInd (FfMacSchedSapUser::SchedDlConfigIndParameters ind
}
}
// RACH
// Random Access procedure: send RARs
Ptr<RarLteControlMessage> rarMsg = Create<RarLteControlMessage> ();
// see TS 36.321 5.1.4; preambles were sent two frames ago
// (plus 3GPP counts subframes from 0, not 1)
uint16_t raRnti = m_subframeNo - 3;
rarMsg->SetRaRnti (raRnti);
for (unsigned int i = 0; i < ind.m_buildRarList.size (); i++)

View File

@@ -938,6 +938,7 @@ LteSpectrumPhy::EndRxData ()
{
UlInfoListElement_s harqUlInfo;
harqUlInfo.m_rnti = tbId.m_rnti;
harqUlInfo.m_tpc = 0;
if ((*itTb).second.corrupt)
{
harqUlInfo.m_receptionStatus = UlInfoListElement_s::NotOk;