Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
It can happen that users put the call to MSG_config before the one to MSG_init (hello...
authormquinson <mquinson@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Thu, 5 Jul 2007 16:56:46 +0000 (16:56 +0000)
committermquinson <mquinson@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Thu, 5 Jul 2007 16:56:46 +0000 (16:56 +0000)
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@3662 48e7efb5-ca39-0410-a469-dd3cf9ba447f

src/msg/msg_config.c

index 811d1b5..7685c1a 100644 (file)
  * Example:
  * MSG_config("surf_workstation_model","KCCFLN05");
  */
-void MSG_config(const char *name, ...) 
-{
+void MSG_config(const char *name, ...) {
+  
+  if (!msg_global) {
+     fprintf(stderr, "ERROR: Please call MSG_init() before using MSG_config()\n");
+     abort();
+  }
+   
+   
   va_list pa;
   /*  xbt_cfg_dump("msg_cfg_set","",_msg_cfg_set);*/
   va_start(pa,name);