Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Make GTNETS compatible with new parsing and variable name convention.
[simgrid.git] / src / simix / smx_deployment.c
index f973d0b..2ca297f 100644 (file)
@@ -25,8 +25,8 @@ static double kill_time = -1.0;
 static void parse_process_init(void)
 {
   parse_host = xbt_strdup(A_surfxml_process_host);
-  xbt_assert1(SIMIX_host_get_by_name(A_surfxml_process_host),
-             "Unknown host %s", A_surfxml_process_host);
+  xbt_assert1(SIMIX_host_get_by_name(parse_host),
+             "Unknown host %s", parse_host);
   parse_code = SIMIX_get_registered_function(A_surfxml_process_function);
   xbt_assert1(parse_code, "Unknown function %s",
              A_surfxml_process_function);
@@ -122,6 +122,7 @@ void SIMIX_launch_application(const char *file)
 {
   xbt_assert0(simix_global,
              "SIMIX_global_init has to be called before SIMIX_launch_application.");
+  surf_parse_reset_parser();
   surfxml_add_callback(STag_surfxml_process_cb_list, parse_process_init);
   surfxml_add_callback(ETag_surfxml_argument_cb_list, parse_argument);
   surfxml_add_callback(STag_surfxml_prop_cb_list, parse_properties);