Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The example from the README fails on FreeBSD #98

Open
yurivict opened this issue Jul 19, 2024 · 1 comment
Open

The example from the README fails on FreeBSD #98

yurivict opened this issue Jul 19, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@yurivict
Copy link

This program fails:

from dlinfo import DLInfo
import ctypes

lib = ctypes.cdll.LoadLibrary(ctypes.util.find_library('c'))
dlinfo = DLInfo(lib)
print(dlinfo.path)
Traceback (most recent call last):
  File "/usr/ports/devel/py-dlinfo/x.py", line 8, in <module>
    print(dlinfo.path)
          ^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/dlinfo/_glibc.py", line 46, in path
    return self._linkmap.contents.l_name.decode(sys.getdefaultencoding())
           ^^^^^^^^^^^^^^^^^^^^^^
ValueError: NULL pointer access
@yurivict yurivict changed the title The example from README fails on FreeBSD The example from the README fails on FreeBSD Jul 19, 2024
@fphammerle fphammerle added the bug Something isn't working label Jul 19, 2024
@fphammerle
Copy link
Contributor

Sorry, I do not have a FreeBSD system for debugging. Please submit a pull request if you find a fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants