It doesn't trigger a popup in console/batch mode.

Signed-off-by: Antonin Décimo <anto...@tarides.com>
---
 mingw-w64-libraries/winpthreads/tests/t_clock_getres.c   | 9 +--------
 mingw-w64-libraries/winpthreads/tests/t_clock_gettime.c  | 9 +--------
 .../winpthreads/tests/t_clock_nanosleep.c                | 9 +--------
 mingw-w64-libraries/winpthreads/tests/t_clock_settime.c  | 9 +--------
 4 files changed, 4 insertions(+), 32 deletions(-)

diff --git a/mingw-w64-libraries/winpthreads/tests/t_clock_getres.c 
b/mingw-w64-libraries/winpthreads/tests/t_clock_getres.c
index 3804a629e..03442d079 100644
--- a/mingw-w64-libraries/winpthreads/tests/t_clock_getres.c
+++ b/mingw-w64-libraries/winpthreads/tests/t_clock_getres.c
@@ -1,18 +1,11 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <time.h>
+#include <assert.h>
 #include <pthread.h>
 
 #define POW10_9                 1000000000
 
-#define assert(_Expression) (void)( (!!(_Expression)) || 
(_my_assert(#_Expression, __FILE__, __LINE__), 0) )
-
-static __inline void _my_assert(char *message, char *file, unsigned int line)
-{
-    fprintf(stderr, "Assertion failed: %s , file %s, line %u\n", message, 
file, line);
-    exit(1);
-}
-
 double sub_and_div(const struct timespec *t1, const struct timespec *t2, const 
struct timespec *r)
 {
     __int64 diff = (t2->tv_sec - t1->tv_sec) * POW10_9 + (t2->tv_nsec - 
t1->tv_nsec);
diff --git a/mingw-w64-libraries/winpthreads/tests/t_clock_gettime.c 
b/mingw-w64-libraries/winpthreads/tests/t_clock_gettime.c
index 23ff0a259..7e2db90d5 100644
--- a/mingw-w64-libraries/winpthreads/tests/t_clock_gettime.c
+++ b/mingw-w64-libraries/winpthreads/tests/t_clock_gettime.c
@@ -2,16 +2,9 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <time.h>
+#include <assert.h>
 #include <pthread.h>
 
-#define assert(_Expression) (void)( (!!(_Expression)) || 
(_my_assert(#_Expression, __FILE__, __LINE__), 0) )
-
-static __inline void _my_assert(char *message, char *file, unsigned int line)
-{
-    fprintf(stderr, "Assertion failed: %s , file %s, line %u\n", message, 
file, line);
-    exit(1);
-}
-
 void test_clock_gettime()
 {
     int rc;
diff --git a/mingw-w64-libraries/winpthreads/tests/t_clock_nanosleep.c 
b/mingw-w64-libraries/winpthreads/tests/t_clock_nanosleep.c
index f707a3061..2077fba74 100644
--- a/mingw-w64-libraries/winpthreads/tests/t_clock_nanosleep.c
+++ b/mingw-w64-libraries/winpthreads/tests/t_clock_nanosleep.c
@@ -3,16 +3,9 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <time.h>
+#include <assert.h>
 #include <pthread.h>
 
-#define assert(_Expression) (void)( (!!(_Expression)) || 
(_my_assert(#_Expression, __FILE__, __LINE__), 0) )
-
-static __inline void _my_assert(char *message, char *file, unsigned int line)
-{
-    fprintf(stderr, "Assertion failed: %s , file %s, line %u\n", message, 
file, line);
-    exit(1);
-}
-
 void test_clock_nanosleep()
 {
     int rc;
diff --git a/mingw-w64-libraries/winpthreads/tests/t_clock_settime.c 
b/mingw-w64-libraries/winpthreads/tests/t_clock_settime.c
index 3a79704f1..d6dc1e45d 100644
--- a/mingw-w64-libraries/winpthreads/tests/t_clock_settime.c
+++ b/mingw-w64-libraries/winpthreads/tests/t_clock_settime.c
@@ -3,16 +3,9 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <time.h>
+#include <assert.h>
 #include <pthread.h>
 
-#define assert(_Expression) (void)( (!!(_Expression)) || 
(_my_assert(#_Expression, __FILE__, __LINE__), 0) )
-
-static __inline void _my_assert(char *message, char *file, unsigned int line)
-{
-    fprintf(stderr, "Assertion failed: %s , file %s, line %u\n", message, 
file, line);
-    exit(1);
-}
-
 void test_clock_settime()
 {
     int rc;
-- 
2.43.0



_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to