*** unix/tclUnixInit.c	2011-01-31 08:28:11.817789927 +0100
--- unix/tclUnixInit.c	2011-01-31 08:50:25.795446269 +0100
***************
*** 1094,1102 ****
--- 1094,1110 ----
  	if (stackGrowsDown) {
  	    tsdPtr->stackBound = (int *) ((char *)tsdPtr->outerVarPtr -
  		    stackSize);
+ 	    if (tsdPtr->stackBound > tsdPtr->outerVarPtr) {
+ 	    	/* overflow, that should never happen, just set it to a very low value */
+ 	    	tsdPtr->stackBound = (int *) (getpagesize() * TCL_RESERVED_STACK_PAGES);
+ 	    }
  	} else {
  	    tsdPtr->stackBound = (int *) ((char *)tsdPtr->outerVarPtr +
  		    stackSize);
+ 	    if (tsdPtr->stackBound < tsdPtr->outerVarPtr) {
+ 	    	/* overflow, that should never happen, just set it to a very high value */
+ 	    	tsdPtr->stackBound = (int *) -(getpagesize() * TCL_RESERVED_STACK_PAGES);
+ 	    }
  	}
      }
  
