From: Ivan Maidanski Date: Mon, 24 Apr 2017 17:47:35 +0000 (+0300) Subject: Workaround 'value of abort unknown' cppcheck info message X-Git-Tag: v7.6.0~21 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6357ec8f32b2ebbbd94f480d785ceeab15a2303a;p=libatomic_ops Workaround 'value of abort unknown' cppcheck info message (fix commit 9f4a38e) * src/atomic_ops_malloc.c [_WIN32_WCE || __MINGW32CE__] (abort): Check defined(AO_HAVE_abort) instead of defined(abort). * tests/run_parallel.h [_WIN32_WCE || __MINGW32CE__] (abort): Likewise. * tests/test_stack.c [_WIN32_WCE || __MINGW32CE__] (abort): Likewise. --- diff --git a/src/atomic_ops_malloc.c b/src/atomic_ops_malloc.c index 74c96c0..4748e6a 100644 --- a/src/atomic_ops_malloc.c +++ b/src/atomic_ops_malloc.c @@ -27,7 +27,7 @@ # include #endif -#if (defined(_WIN32_WCE) || defined(__MINGW32CE__)) && !defined(abort) +#if (defined(_WIN32_WCE) || defined(__MINGW32CE__)) && !defined(AO_HAVE_abort) # define abort() _exit(-1) /* there is no abort() in WinCE */ #endif diff --git a/tests/run_parallel.h b/tests/run_parallel.h index 7500efa..c61d359 100644 --- a/tests/run_parallel.h +++ b/tests/run_parallel.h @@ -33,7 +33,7 @@ #include "atomic_ops.h" -#if (defined(_WIN32_WCE) || defined(__MINGW32CE__)) && !defined(abort) +#if (defined(_WIN32_WCE) || defined(__MINGW32CE__)) && !defined(AO_HAVE_abort) # define abort() _exit(-1) /* there is no abort() in WinCE */ #endif diff --git a/tests/test_stack.c b/tests/test_stack.c index 623f208..71c649f 100644 --- a/tests/test_stack.c +++ b/tests/test_stack.c @@ -43,7 +43,7 @@ #include "atomic_ops_stack.h" /* includes atomic_ops.h as well */ -#if (defined(_WIN32_WCE) || defined(__MINGW32CE__)) && !defined(abort) +#if (defined(_WIN32_WCE) || defined(__MINGW32CE__)) && !defined(AO_HAVE_abort) # define abort() _exit(-1) /* there is no abort() in WinCE */ #endif