Bugzilla – Bug 420
static-speed-helper
Last modified: 2008-11-26 06:43:51 UTC
Valgrind says that m_paused in static-speed-helper.cc is uninitialized at line 70. This appears to be the case since there are two of three constructors that do not initialize it.
It would be nice to see the full valgrind warning.
==24061== Conditional jump or move depends on uninitialised value(s) ==24061== at 0x542F44E: ns3::StaticSpeedHelper::Update() const (static-speed-helper.cc:70) ==24061== by 0x5433889: ns3::RandomWalk2dMobilityModel::Start() (random-walk-2d-mobility-model.cc:83) ==24061== by 0x5432B0F: ns3::EventImpl* ns3::MakeEvent<void (ns3::RandomWalk2dMobilityModel::*)(), ns3::RandomWalk2dMobilityModel*>(void (ns3::RandomWalk2dMobilityModel::*)(), ns3::RandomWalk2dMobilityModel*)::EventMemberImpl0::Notify() (make-event.h:88) ==24061== by 0x52396FA: ns3::EventImpl::Invoke() (event-impl.cc:39) ==24061== by 0x5252488: ns3::DefaultSimulatorImpl::ProcessOneEvent() (default-simulator-impl.cc:121) ==24061== by 0x52524C9: ns3::DefaultSimulatorImpl::Run() (default-simulator-impl.cc:152) ==24061== by 0x5242118: ns3::Simulator::Run() (simulator.cc:151) ==24061== by 0x40EC95: main (wifi-wired-bridging.cc:150)
I reviewed the code carefully and I believe that this fix is safe because all users of the StaticSpeedHelper code invoke the Unpause method correctly. We need more regression tests for mobility models :/ changeset 29bb5689faa4