]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[3.13] gh-130052: Fix search_map_for_section() error handling (GH-132594) (#132598)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Wed, 16 Apr 2025 14:21:58 +0000 (16:21 +0200)
committerGitHub <noreply@github.com>
Wed, 16 Apr 2025 14:21:58 +0000 (14:21 +0000)
commitff3f6588c3ecb6746a33f14030a90eb32467eece
tree42417a44fcc9bf158713b8bb25901bf897e19907
parentee8f681252372cca489e49a061d83c6f0138186c
[3.13] gh-130052: Fix search_map_for_section() error handling (GH-132594) (#132598)

gh-130052: Fix search_map_for_section() error handling (GH-132594)

* Don't call close() if the file descriptor is negative.
* If close() fails, chain the existing exception.
(cherry picked from commit 014c7f90478780b18d0e33d456483178c8dcc665)

Co-authored-by: Victor Stinner <vstinner@python.org>
Modules/_testexternalinspection.c