Skip to content

Commit cf33d89

Browse files
sobolevnmiss-islington
authored andcommitted
gh-153252: Fix error handling in _PyCompile_CodeGen (GH-153253)
(cherry picked from commit a74280e) Co-authored-by: sobolevn <mail@sobolevn.me>
1 parent 97a45b0 commit cf33d89

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Python/compile.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1641,7 +1641,7 @@ _PyCompile_CodeGen(PyObject *ast, PyObject *filename, PyCompilerFlags *pflags,
16411641

16421642
metadata = PyDict_New();
16431643
if (metadata == NULL) {
1644-
return NULL;
1644+
goto finally;
16451645
}
16461646

16471647
if (compiler_codegen(c, mod) < 0) {

0 commit comments

Comments
 (0)