Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
fix potential segfault happening when only -trace is provided to smpi
authordegomme <augustin.degomme@unibas.ch>
Wed, 20 Jan 2016 17:09:48 +0000 (18:09 +0100)
committerdegomme <augustin.degomme@unibas.ch>
Wed, 20 Jan 2016 17:13:35 +0000 (18:13 +0100)
src/surf/sg_platf.cpp

index c925a4c..c55dd85 100644 (file)
@@ -117,7 +117,7 @@ void sg_platf_new_router(sg_platf_router_cbarg_t router)
     XBT_DEBUG("Having set router coordinates for '%s'",router->id);
   }
 
-  if (TRACE_is_enabled())
+  if (TRACE_is_enabled() && TRACE_needs_platform())
     sg_instr_new_router(router);
 }