diff options
author | Michael W. Hudson <mwh@python.net> | 2002-10-02 13:13:45 (GMT) |
---|---|---|
committer | Michael W. Hudson <mwh@python.net> | 2002-10-02 13:13:45 (GMT) |
commit | fb4d6ecd0757c0863b8a2e45a57a6dfec13fbff6 (patch) | |
tree | 990b8cb3dffce52639bfa8929f6956ad0f1e49a2 /Python/ceval.c | |
parent | 3c6d6f2ff70a4ff6c7894c64ff8f86c77092797a (diff) | |
download | cpython-fb4d6ecd0757c0863b8a2e45a57a6dfec13fbff6.zip cpython-fb4d6ecd0757c0863b8a2e45a57a6dfec13fbff6.tar.gz cpython-fb4d6ecd0757c0863b8a2e45a57a6dfec13fbff6.tar.bz2 |
Fix for the recursion_level bug Armin Rigo reported in sf
patch #617312, both on the trunk and the 22-maint branch.
Also added a test case, and ported the test_trace I wrote for HEAD
to 2.2.2 (with all those horrible extra 'line' events ;-).
Diffstat (limited to 'Python/ceval.c')
-rw-r--r-- | Python/ceval.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Python/ceval.c b/Python/ceval.c index 362cd0b..4930433 100644 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -636,6 +636,8 @@ eval_frame(PyFrameObject *f) if (call_trace(tstate->c_tracefunc, tstate->c_traceobj, f, PyTrace_CALL, Py_None)) { /* Trace function raised an error */ + --tstate->recursion_depth; + tstate->frame = f->f_back; return NULL; } } @@ -646,6 +648,8 @@ eval_frame(PyFrameObject *f) tstate->c_profileobj, f, PyTrace_CALL, Py_None)) { /* Profile function raised an error */ + --tstate->recursion_depth; + tstate->frame = f->f_back; return NULL; } } |