Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
move surf::As to s4u::As
[simgrid.git] / src / surf / surf_interface.cpp
index 8cef095..e1424f4 100644 (file)
@@ -266,6 +266,9 @@ void sg_version(int *ver_major,int *ver_minor,int *ver_patch) {
 
 void surf_init(int *argc, char **argv)
 {
+  if (host_list != nullptr) // Already initialized
+    return;
+
   XBT_DEBUG("Create all Libs");
   host_list = xbt_dict_new_homogeneous([](void*p) {
     simgrid::s4u::Host* host = static_cast<simgrid::s4u::Host*>(p);