From: Jeremy Hylton Date: Wed, 5 Nov 2003 17:29:35 +0000 (+0000) Subject: Make undetected error on stack unwind a fatal error. X-Git-Tag: v2.4a1~1326 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=904ed86a777f5e55d370e997f8efb433052ca6e3;p=python Make undetected error on stack unwind a fatal error. --- diff --git a/Python/ceval.c b/Python/ceval.c index fe8aca5a1d..df6f0e9aac 100644 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -2306,10 +2306,10 @@ eval_frame(PyFrameObject *f) else { /* This check is expensive! */ if (PyErr_Occurred()) { - fprintf(stderr, - "XXX undetected error (why=%d)\n", - why); - why = WHY_EXCEPTION; + char buf[1024]; + sprintf(buf, "Stack unwind with exception " + "set and why=%d", why); + Py_FatalError(buf); } } #endif