Thanks to visit codestin.com
Credit goes to github.com

Skip to content

bpo-40048: Fix _PyCode_InitOpcache() error path #19691

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 24, 2020
Merged

bpo-40048: Fix _PyCode_InitOpcache() error path #19691

merged 1 commit into from
Apr 24, 2020

Conversation

vstinner
Copy link
Member

@vstinner vstinner commented Apr 23, 2020

If _PyCode_InitOpcache() fails in _PyEval_EvalFrameDefault(), use
"goto exit_eval_frame;" rather than "return NULL;" to exit the
function in a consistent state. For example, tstate->frame is now
reset properly.

https://bugs.python.org/issue40048

If _PyCode_InitOpcache() fails in _PyEval_EvalFrameDefault(), use
"goto exit_eval_frame;" rather than "return NULL;" to exit the
function in a consistent state. For example, tstate->frame is now
reset properly.
@vstinner
Copy link
Member Author

@methane or @pablogsal: Would you mind to review this fix for https://bugs.python.org/issue40048 ?

@vstinner vstinner merged commit 2510494 into python:master Apr 24, 2020
@miss-islington
Copy link
Contributor

Thanks @vstinner for the PR 🌮🎉.. I'm working now to backport this PR to: 3.8.
🐍🍒⛏🤖

@vstinner vstinner deleted the opcache_fail branch April 24, 2020 00:43
@miss-islington
Copy link
Contributor

Sorry @vstinner, I had trouble checking out the 3.8 backport branch.
Please backport using cherry_picker on command line.
cherry_picker 25104949a5a60ff86c10691e184ce2ecb500159b 3.8

@bedevere-bot
Copy link

GH-19698 is a backport of this pull request to the 3.8 branch.

vstinner added a commit that referenced this pull request Apr 24, 2020
If _PyCode_InitOpcache() fails in _PyEval_EvalFrameDefault(), use
"goto exit_eval_frame;" rather than "return NULL;" to exit the
function in a consistent state. For example, tstate->frame is now
reset properly.

(cherry picked from commit 2510494)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants