Browse Source

Print to stderr when an exception triggers an abort

Caleb James DeLisle 5 years ago
parent
commit
356ce8c9c1
1 changed files with 3 additions and 3 deletions
  1. 3 3
      exception/Except.c

+ 3 - 3
exception/Except.c

@@ -41,9 +41,9 @@ void Except__throw(char* file, int line, struct Except* eh, char* format, ...)
         }
         eh->exception(eh->message, eh);
     } else {
-        printf("%s:%d ", subFile, line);
-        vprintf(format, args);
-        printf("\n");
+        fprintf(stderr, "%s:%d ", subFile, line);
+        vfprintf(stderr, format, args);
+        fprintf(stderr, "\n");
     }
     abort();
     exit(100);