Skip to content

Commit b02a22b

Browse files
committed
added error reporting macro for invalid configuration
1 parent 44fadda commit b02a22b

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

examples/benchmark/tls_bench.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,10 @@ Or
7878
#undef HAVE_PTHREAD
7979
#endif
8080
#endif
81+
/* Conversely, if both server and client are enabled, we must require pthreads */
82+
#if !defined(NO_WOLFSSL_CLIENT) && !defined(NO_WOLFSSL_SERVER) && !defined(HAVE_PTHREAD)
83+
#error "pthreads must be enabled if building benchmark suite to run both client and server. Please define HAVE_PTHREAD if your platform supports it."
84+
#endif
8185

8286
#ifdef HAVE_PTHREAD
8387
#include <pthread.h>

0 commit comments

Comments
 (0)