#include "xbt/peer.h"
#include "xbt/config.h" /* prototypes of this module */
-#include "surf/surf.h" /* COORD_HOST_LEVEL and COORD_ASR_LEVEL */
+#include "surf/surf_routing.h" /* COORD_HOST_LEVEL and COORD_ASR_LEVEL */
+
+xbt_lib_t host_lib;
+int COORD_HOST_LEVEL; //Coordinates level
+xbt_lib_t as_router_lib;
+int COORD_ASR_LEVEL; //Coordinates level
XBT_LOG_NEW_DEFAULT_SUBCATEGORY(xbt_cfg, xbt, "configuration support");
variable = xbt_dict_get((xbt_dict_t) cfg, name);
}
CATCH(e) {
- /* put it back on what won't get freed, ie within "options" and out of "optionlist_cpy" */
- name = (char *) (optionlist_cpy - name + options);
- free(optionlist_cpy);
if (e.category == not_found_error) {
xbt_ex_free(e);
+ name = xbt_strdup(name);
+ free(optionlist_cpy);
THROWF(not_found_error, 0,
"No registered variable corresponding to '%s'.", name);
}
+ free(optionlist_cpy);
RETHROW;
}