diff options
author | Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> | 2023-06-26 08:31:01 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-06-26 08:31:01 (GMT) |
commit | b786fe8a0913e4ecfc5f04749a36a85a8aa6fc1c (patch) | |
tree | 8d6d286384e1f87cd00a69c7a2d41c87a9dfb1a0 /Python | |
parent | e9366df3ecb360882020131def3f5c400ae54ba8 (diff) | |
download | cpython-b786fe8a0913e4ecfc5f04749a36a85a8aa6fc1c.zip cpython-b786fe8a0913e4ecfc5f04749a36a85a8aa6fc1c.tar.gz cpython-b786fe8a0913e4ecfc5f04749a36a85a8aa6fc1c.tar.bz2 |
[3.12] gh-105979: Fix exception handling in `unmarshal_frozen_code` (`Python/import.c`) (GH-105980) (#106055)
gh-105979: Fix exception handling in `unmarshal_frozen_code` (`Python/import.c`) (GH-105980)
(cherry picked from commit cd5280367a3a7065d13b8f7234474f7a2e9a18fd)
Co-authored-by: chgnrdv <52372310+chgnrdv@users.noreply.github.com>
Diffstat (limited to 'Python')
-rw-r--r-- | Python/import.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Python/import.c b/Python/import.c index 24723d6..d10c5ce 100644 --- a/Python/import.c +++ b/Python/import.c @@ -2053,6 +2053,7 @@ unmarshal_frozen_code(PyInterpreterState *interp, struct frozen_info *info) PyObject *co = PyMarshal_ReadObjectFromString(info->data, info->size); if (co == NULL) { /* Does not contain executable code. */ + PyErr_Clear(); set_frozen_error(FROZEN_INVALID, info->nameobj); return NULL; } |