]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[3.14] gh-143304: Fix ctypes.CDLL to honor handle parameter on POSIX systems (GH...
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Thu, 5 Mar 2026 14:34:32 +0000 (15:34 +0100)
committerGitHub <noreply@github.com>
Thu, 5 Mar 2026 14:34:32 +0000 (15:34 +0100)
commitc5542c905f1f54ccf9acb4e45086ba4cfb3de9bc
treed0375d13697775bdfdbaf67bb7101ab613cf107b
parent7b3e6bde26927e093fd81bf699ddd144a7b277d0
[3.14] gh-143304: Fix ctypes.CDLL to honor handle parameter on POSIX systems (GH-143318) (GH-145172)

The handle parameter was being ignored in the POSIX implementation
of CDLL._load_library(), causing it to always call _dlopen() even
when a valid handle was provided. This was a regression introduced
in recent refactoring.
(cherry picked from commit 27ded243485670fa836c9bb421e37a6ef16eca8e)

Co-authored-by: Arjit Singh Grover <143692910+Koolvansh07@users.noreply.github.com>
Co-authored-by: Petr Viktorin <encukou@gmail.com>
Lib/ctypes/__init__.py
Lib/test/test_ctypes/test_loading.py
Misc/NEWS.d/next/Library/2026-01-01-05-26-00.gh-issue-143304.Kv7x9Q.rst [new file with mode: 0644]