From a5e7a20c939fabb426fd4a85c28afc135f2623e9 Mon Sep 17 00:00:00 2001 From: Lealem Amedie Date: Wed, 22 Mar 2023 17:29:13 -0600 Subject: [PATCH] Fix for logic gating strerror_r() --- wolfcrypt/test/test.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wolfcrypt/test/test.c b/wolfcrypt/test/test.c index 6fd425534..5f80924e1 100644 --- a/wolfcrypt/test/test.c +++ b/wolfcrypt/test/test.c @@ -651,7 +651,8 @@ static void render_error_message(const char* msg, int es) * infelicitous... */ #if !defined(STRING_USER) && !defined(NO_ERROR_STRINGS) && \ - (defined(_GNU_SOURCE) || defined(__USE_GNU) || \ + (defined(__STDC_VERSION__) && (__STDC_VERSION__ > 199901L)) && \ + ((defined(__GLIBC__) && (__GLIBC__ >= 2)) || \ (defined(__USE_XOPEN2K) && \ defined(_POSIX_C_SOURCE) && \ (_POSIX_C_SOURCE >= 200112L)))