Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[sonar] Constify pointer and reference local variables in examples/.
[simgrid.git] / examples / s4u / platform-properties / s4u-platform-properties.cpp
index 12e793d..7167722 100644 (file)
@@ -84,7 +84,7 @@ static void david(std::vector<std::string> /*args*/)
 static void bob(std::vector<std::string> /*args*/)
 {
   /* this host also tests the properties of the AS*/
-  simgrid::s4u::NetZone* root = simgrid::s4u::Engine::get_instance()->get_netzone_root();
+  const simgrid::s4u::NetZone* root = simgrid::s4u::Engine::get_instance()->get_netzone_root();
   XBT_INFO("== Print the properties of the root zone");
   XBT_INFO("   Zone property: filename -> %s", root->get_property("filename"));
   XBT_INFO("   Zone property: date -> %s", root->get_property("date"));