Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
We may want to use this function in examples.
[simgrid.git] / src / surf / surf_routing.c
index d0a5328..526fdfd 100644 (file)
@@ -1069,7 +1069,7 @@ static xbt_dynar_t get_onelink_routes(void)
   return recursive_get_onelink_routes(global_routing->root);
 }
 
-static e_surf_network_element_type_t get_network_element_type(const char
+e_surf_network_element_type_t get_network_element_type(const char
                                                               *name)
 {
   network_element_info_t rc = NULL;
@@ -1793,7 +1793,6 @@ static void model_floyd_set_route(routing_component_t rc, const char *src,
                              (void*)link_route_to_test,
                                  (int_f_cpvoid_cpvoid_t) surf_pointer_resource_cmp),
                                  "The route between \"%s\" and \"%s\" already exists", src,dst);
-                       xbt_free(link_route_to_test);
                }
                else
                {
@@ -3900,7 +3899,7 @@ static void routing_parse_Srandom(void)
          double mean, std, min, max, seed;
          char *random_id = A_surfxml_random_id;
          char *random_radical = A_surfxml_random_radical;
-         char *rd_name;
+         char *rd_name = NULL;
          char *rd_value;
          surf_parse_get_double(&mean,A_surfxml_random_mean);
          surf_parse_get_double(&std,A_surfxml_random_std_deviation);