From 615dce02b10474799a27f2bb99924d73b2c11a72 Mon Sep 17 00:00:00 2001 From: Tony Garnock-Jones Date: Wed, 29 Dec 2010 09:11:53 -0500 Subject: [PATCH] Looks like 10.5 has more aggressive stack requirements than 10.6. --- harness.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/harness.c b/harness.c index a43d7d3..449521f 100644 --- a/harness.c +++ b/harness.c @@ -18,11 +18,17 @@ typedef unsigned char u_char; #ifdef __APPLE__ /* Bollocks. Looks like OS X chokes unless STACK_SIZE is a multiple of 32k. */ -#define STACK_SIZE 32768 +# include +# if !defined(MAC_OS_X_VERSION_10_6) || MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_6 +/* Hmm, and looks like 10.5 has more aggressive stack requirements than 10.6. */ +# define STACK_SIZE 65536 +# else +# define STACK_SIZE 32768 +# endif #elif linux -#define STACK_SIZE 32768 +# define STACK_SIZE 32768 #else -#error Define STACK_SIZE for your platform. It should probably not be less than 32k? +# error Define STACK_SIZE for your platform. It should probably not be less than 32k? #endif Process *current_process = NULL;