Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[mc] Fix bug when trying to handle DW_OP_regN in MC_dwarf_resolve_location
[simgrid.git] / src / surf / network_gtnets.c
index b959f55..4392bb3 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2007, 2008, 2009, 2010. The SimGrid Team.
+/* Copyright (c) 2007-2013. The SimGrid Team.
  * All rights reserved.                                                     */
 
 /* This program is free software; you can redistribute it and/or modify it
@@ -62,7 +62,7 @@ static void route_new(int src_id, int dst_id, xbt_dynar_t links,
           src_id, dst_id, links, nb_link);
 
   /* Build the list of gtnets link IDs */
-  gtnets_links = (int *) calloc(nb_link, sizeof(int));
+  gtnets_links = xbt_new0(int, nb_link);
   i = 0;
   xbt_dynar_foreach(links, cursor, link) {
     gtnets_links[i++] = link->id;
@@ -210,7 +210,7 @@ static double share_resources(double now)
 
   XBT_DEBUG("Calling gtnets_get_time_to_next_flow_completion");
   time_to_next_flow_completion = gtnets_get_time_to_next_flow_completion();
-  XBT_DEBUG("gtnets_get_time_to_next_flow_completion received %lg",
+  XBT_DEBUG("gtnets_get_time_to_next_flow_completion received %g",
          time_to_next_flow_completion);
 
   return time_to_next_flow_completion;