Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Visual C++ already declare the environ variable in the stdlib.h. So this redeclaratio...
[simgrid.git] / src / xbt / ex.c
index 8abd459..21215dd 100644 (file)
@@ -81,7 +81,9 @@ void xbt_backtrace_display_current(void) {
   xbt_backtrace_display(&e);
 }
 
+#ifndef WIN32
 extern char **environ; /* the environment, as specified by the opengroup */
+#endif
 
 void xbt_ex_setup_backtrace(xbt_ex_t *e)  {
 #if defined(HAVE_EXECINFO_H) && defined(HAVE_POPEN) && defined(ADDR2LINE)
@@ -323,7 +325,7 @@ void xbt_ex_display(xbt_ex_t *e)  {
   char *thrower=NULL;
 
   if (e->remote)
-    bprintf(" on host %s(%d)",e->host,e->pid);
+    thrower = bprintf(" on host %s(%d)",e->host,e->pid);
 
   fprintf(stderr,
          "** SimGrid: UNCAUGHT EXCEPTION received on %s(%d): category: %s; value: %d\n"