--- a/src/contrib/energy/test/basic-energy-model-test.cc Wed Jul 07 21:54:32 2010 -0700
+++ b/src/contrib/energy/test/basic-energy-model-test.cc Thu Jul 08 11:04:25 2010 -0400
@@ -132,7 +132,7 @@
Ptr<BasicRadioEnergyModel> devModel =
DynamicCast<BasicRadioEnergyModel> (modelList[0]);
// check pointer
- NS_TEST_ASSERT_MSG_NE (NULL, devModel, "NULL pointer to device model!");
+ NS_TEST_ASSERT_MSG_NE (0, devModel, "NULL pointer to device model!");
// schedule change of state
Simulator::Schedule (Seconds (m_timeS),
@@ -315,7 +315,7 @@
* the floor here because initial update is at time = 0.
*/
double tmp = ceil (simTimeS / updateIntervalS);
- int numOfUpdates = (tmp == 0) ? 1 : tmp;
+ int numOfUpdates = (tmp == 0) ? 1 : static_cast<int> (tmp);
/*
* Every update will trigger *all* DeviceEnergyModels to react, therefore the
* total count should be numOfUpdates * m_numOfModels ^ 2