Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
sanitize the way parsing callbacks of the routing submodule are registered
[simgrid.git] / src / surf / surf_routing.c
index 987196f..eaf46a2 100644 (file)
@@ -835,11 +835,14 @@ void routing_model_create(size_t size_of_links, void *loopback, double_f_cpvoid_
   get_link_latency = get_link_latency_fun;
   /* no current routing at moment */
   current_routing = NULL;
+}
 
-  /* parse generic elements */
+void routing_register_callbacks() {
   sg_platf_host_add_cb(parse_S_host);
   sg_platf_router_add_cb(parse_S_router);
 
+  surfxml_add_callback(STag_surfxml_random_cb_list, &routing_parse_Srandom);
+
   surfxml_add_callback(STag_surfxml_route_cb_list,
       &parse_S_route_new_and_endpoints_XML);
   surfxml_add_callback(STag_surfxml_ASroute_cb_list,
@@ -867,12 +870,6 @@ void routing_model_create(size_t size_of_links, void *loopback, double_f_cpvoid_
 #endif
 }
 
-void surf_parse_add_callback_config(void)
-{
-  surfxml_add_callback(STag_surfxml_random_cb_list, &routing_parse_Srandom);
-}
-
-
 /* ************************************************** */
 /* ********** PATERN FOR NEW ROUTING **************** */