Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Merge branch 'master' of github.com:mquinson/simgrid
[simgrid.git] / src / simgrid / host.cpp
index da0f26d..98049d9 100644 (file)
@@ -68,7 +68,7 @@ xbt_dynar_t sg_hosts_as_dynar(void)
   const char* name = nullptr;
   simgrid::s4u::Host* host = nullptr;
   xbt_dict_foreach(host_list, cursor, name, host)
-    if (host && host->pimpl_netcard && host->pimpl_netcard->getRcType() == SURF_NETWORK_ELEMENT_HOST)
+    if (host && host->pimpl_netcard && host->pimpl_netcard->isHost())
        xbt_dynar_push(res, &host);
   return res;
 }
@@ -86,10 +86,6 @@ void sg_host_init()
     __MSG_host_priv_free((msg_host_priv_t) p);
   });
 
-  ROUTING_HOST_LEVEL = simgrid::s4u::Host::extension_create([](void *p) {
-    delete static_cast<simgrid::surf::NetCard*>(p);
-  });
-
   SIMIX_HOST_LEVEL = simgrid::s4u::Host::extension_create(SIMIX_host_destroy);
   USER_HOST_LEVEL = simgrid::s4u::Host::extension_create(NULL);
 }