Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Export public data in a way where we can specify that they are extern C (plus buglet...
authormquinson <mquinson@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Mon, 4 Jun 2007 08:42:47 +0000 (08:42 +0000)
committermquinson <mquinson@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Mon, 4 Jun 2007 08:42:47 +0000 (08:42 +0000)
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@3549 48e7efb5-ca39-0410-a469-dd3cf9ba447f

src/xbt/ex.c
src/xbt/log.c

index d51f990..f758c70 100644 (file)
@@ -288,8 +288,8 @@ void __xbt_ex_terminate_default(xbt_ex_t *e)  {
 }
 
 /* the externally visible API */
 }
 
 /* the externally visible API */
-ex_ctx_cb_t XBT_PUBLIC_DATA  __xbt_ex_ctx       = &__xbt_ex_ctx_default;
-ex_term_cb_t XBT_PUBLIC_DATA __xbt_ex_terminate = &__xbt_ex_terminate_default;
+XBT_PUBLIC_DATA(ex_ctx_cb_t)  __xbt_ex_ctx       = &__xbt_ex_ctx_default;
+XBT_PUBLIC_DATA(ex_term_cb_t) __xbt_ex_terminate = &__xbt_ex_terminate_default;
 
 
 void xbt_ex_free(xbt_ex_t e) {
 
 
 void xbt_ex_free(xbt_ex_t e) {
index 55fa192..1e63f7a 100644 (file)
@@ -369,7 +369,7 @@ const char *xbt_log_priority_names[8] = {
   "CRITICAL"
 };
 
   "CRITICAL"
 };
 
-s_xbt_log_category_t XBT_PUBLIC_DATA  _XBT_LOGV(XBT_LOG_ROOT_CAT) = {
+XBT_PUBLIC_DATA(s_xbt_log_category_t)  _XBT_LOGV(XBT_LOG_ROOT_CAT) = {
   0, 0, 0,
   "root", xbt_log_priority_uninitialized, 0,
   NULL, 0
   0, 0, 0,
   "root", xbt_log_priority_uninitialized, 0,
   NULL, 0
@@ -655,8 +655,8 @@ static xbt_log_setting_t _xbt_log_parse_setting(const char* control_string) {
     free(neweq);
   } else {
     char buff[512];
     free(neweq);
   } else {
     char buff[512];
-    snprintf(buff,min(512,eq - dot - 1),"%s",dot+1);
-    THROW1(arg_error,0,"Unknown setting of the log category: %s",buff);
+    snprintf(buff,min(512,eq - dot),"%s",dot+1);
+    THROW1(arg_error,0,"Unknown setting of the log category: '%s'",buff);
   }
   set->catname=(char*)xbt_malloc(dot - name+1);
     
   }
   set->catname=(char*)xbt_malloc(dot - name+1);