]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-131565: Implement ctypes.util.dllist() in the _ctypes extension (GH-154255)
authorSerhiy Storchaka <storchaka@gmail.com>
Wed, 29 Jul 2026 14:47:52 +0000 (17:47 +0300)
committerGitHub <noreply@github.com>
Wed, 29 Jul 2026 14:47:52 +0000 (17:47 +0300)
commitbfc16a71cf18015c47c1b9cae9196e279d8f60d7
tree50d9902994a4559da4c957ee5ca4ecbe8fdf99e9
parentae18daedc75f40fdca7921bee3ce61dd1192c475
gh-131565: Implement ctypes.util.dllist() in the _ctypes extension (GH-154255)

On NetBSD dl_iterate_phdr() reports only the link-map group of the calling
object.  Called through ctypes, the caller is libffi's closure trampoline,
which belongs to no object, so only the main executable was reported.
Calling dl_iterate_phdr() from the _ctypes extension module makes _ctypes
the caller and reports all loaded shared libraries.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Lib/ctypes/util.py
Misc/NEWS.d/next/Library/2026-07-20-17-15-00.gh-issue-131565.dllist.rst [new file with mode: 0644]
Modules/_ctypes/callproc.c
configure
configure.ac
pyconfig.h.in