From e901dd8cf7f762ed12b440d5ee46e953efa50bbb Mon Sep 17 00:00:00 2001 From: Linus Nordberg Date: Mon, 17 Oct 2016 07:47:42 +0200 Subject: Don't use a smaller pthread stack size than what's allowed. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Patch by Kolbjørn Barmen. --- radsecproxy.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/radsecproxy.h b/radsecproxy.h index 0b2aebe..982515c 100644 --- a/radsecproxy.h +++ b/radsecproxy.h @@ -23,7 +23,16 @@ #define MAX_CERT_DEPTH 5 #define STATUS_SERVER_PERIOD 25 #define IDLE_TIMEOUT 300 + +/* We want PTHREAD_STACK_SIZE to be 32768, but some platforms + * have a higher minimum value defined in PTHREAD_STACK_MIN. */ #define PTHREAD_STACK_SIZE 32768 +#if defined(PTHREAD_STACK_MIN) +#if PTHREAD_STACK_MIN > PTHREAD_STACK_SIZE +#undef PTHREAD_STACK_SIZE +#define PTHREAD_STACK_SIZE PTHREAD_STACK_MIN +#endif +#endif /* 27262 is vendor DANTE Ltd. */ #define DEFAULT_TTL_ATTR "27262:1" -- cgit v1.1