Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
another empty function murder
authorMartin Quinson <martin.quinson@loria.fr>
Mon, 14 Nov 2011 16:05:55 +0000 (17:05 +0100)
committerMartin Quinson <martin.quinson@loria.fr>
Mon, 14 Nov 2011 20:20:19 +0000 (21:20 +0100)
src/include/surf/surf.h
src/simix/smx_deployment.c
src/surf/surfxml_parse.c
src/surf/surfxml_parseplatf.c

index 8ac4782..f1a8832 100644 (file)
@@ -672,8 +672,7 @@ XBT_PUBLIC(void) surf_exit(void);
 
 /* Prototypes of the functions that handle the properties */
 XBT_PUBLIC_DATA(xbt_dict_t) current_property_set;       /* the prop set for the currently parsed element (also used in SIMIX) */
-XBT_PUBLIC_DATA(void) parse_properties(const char* prop_id, const char* prop_value);
-XBT_PUBLIC_DATA(void) parse_properties_XML(void);
+XBT_PUBLIC(void) parse_properties(void);
 
 /* surf parse file related (public because called from a test suite) */
 XBT_PUBLIC(void) parse_platform_file(const char *file);
index 262790f..2476a4b 100644 (file)
@@ -112,7 +112,7 @@ void SIMIX_launch_application(const char *file)
 
   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_XML);
+  surfxml_add_callback(STag_surfxml_prop_cb_list, parse_properties);
   surfxml_add_callback(ETag_surfxml_process_cb_list,
                        parse_process_finalize);
 
index 83a8612..aec1820 100644 (file)
@@ -566,19 +566,15 @@ static XBT_INLINE void surfxml_call_cb_functions(xbt_dynar_t cb_list)
 
 /* Prop tag functions */
 
-void parse_properties(const char* prop_id, const char* prop_value)
-{
-       if (!current_property_set)
-           current_property_set = xbt_dict_new();      // Maybe, it should raise an error
-       xbt_dict_set(current_property_set, prop_id, xbt_strdup(prop_value), free);
-}
-
 /**
  * With XML parser
  */
-void parse_properties_XML(void)
+void parse_properties(void)
 {
-  parse_properties(A_surfxml_prop_id, A_surfxml_prop_value);
+  if (!current_property_set)
+      current_property_set = xbt_dict_new();      // Maybe, it should raise an error
+
+  xbt_dict_set(current_property_set, A_surfxml_prop_id, xbt_strdup(A_surfxml_prop_value), free);
 }
 
 
index f04585d..c8216ef 100644 (file)
@@ -137,7 +137,7 @@ void parse_platform_file(const char *file)
   surf_parse_reset_callbacks();
 
   /* Register classical callbacks */
-  surfxml_add_callback(STag_surfxml_prop_cb_list, &parse_properties_XML);
+  surfxml_add_callback(STag_surfxml_prop_cb_list, &parse_properties);
   routing_register_callbacks();
 
   /* init the flex parser */