Skip to content

gh-138756: Fix memory leak in PyInitConfig_Free() - #138759

Merged
vstinner merged 3 commits into
python:mainfrom
vstinner:free_config
Sep 11, 2025
Merged

vstinner merged 3 commits into
python:mainfrom
vstinner:free_config

Conversation

@vstinner

@vstinner vstinner commented Sep 10, 2025 •

Copy link
Copy Markdown
Member
Comment thread Python/initconfig.c Resolved
@vstinner
vstinner enabled auto-merge (squash) September 11, 2025 10:21
@vstinner
vstinner merged commit 96dee64 into python:main Sep 11, 2025
@vstinner
vstinner deleted the free_config branch September 11, 2025 10:46
@miss-islington-app

Copy link
Copy Markdown

Thanks @vstinner for the PR 🌮🎉.. I'm working now to backport this PR to: 3.14.
🐍🍒⛏🤖 I'm not a witch! I'm not a witch!

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Sep 11, 2025
)

Clear also memory of PyConfig members.
(cherry picked from commit 96dee64)

Co-authored-by: Victor Stinner <vstinner@python.org>
@bedevere-app

bedevere-app Bot commented Sep 11, 2025

Copy link
Copy Markdown

GH-138785 is a backport of this pull request to the 3.14 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.14 bugs and security fixes label Sep 11, 2025
@vstinner

Copy link
Copy Markdown
Member Author

Oh, there is another leak: inittab. I wrote #138792 to release inittab as well.

vstinner added a commit that referenced this pull request Oct 7, 2025
…138785)

gh-138756: Fix memory leak in PyInitConfig_Free() (GH-138759)

Clear also memory of PyConfig members.
(cherry picked from commit 96dee64)

Co-authored-by: Victor Stinner <vstinner@python.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

2 participants