Extend array API
[jansson.git] / test / testprogs / util.h
index 6e518a2..ec8e0e4 100644 (file)
@@ -8,10 +8,13 @@
 #ifndef TESTPROGS_UTIL_H
 #define TESTPROGS_UTIL_H
 
+#include <stdlib.h>
+
 #define fail(msg)                                                \
     do {                                                         \
-        fprintf(stderr, "%s:%d: %s\n", __FILE__, __LINE__, msg); \
-        return 1;                                                \
+        fprintf(stderr, "%s:%s:%d: %s\n",                        \
+                __FILE__, __FUNCTION__, __LINE__, msg);          \
+        exit(1);                                                 \
     } while(0)
 
 #endif