diff -r 855608ce92bc Modules/faulthandler.c --- a/Modules/faulthandler.c Thu Mar 12 20:56:45 2015 +0200 +++ b/Modules/faulthandler.c Thu Mar 12 17:44:15 2015 -0500 @@ -952,7 +952,12 @@ return sp; buffer[0] = 1; buffer[4095] = 0; - return stack_overflow(min_sp, max_sp, depth); + sp = stack_overflow(min_sp, max_sp, depth); + if (sp != 0) return sp; + else return (sp+15); /* this should never happen, it's here + * to fool the compiler so it won't + * tail-call optimize (turning the + * recursion into an infinite loop) */ } static PyObject *