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

_resolve can cause luajit to segmentation fault #308

Open
dagle opened this issue Jan 30, 2023 · 0 comments
Open

_resolve can cause luajit to segmentation fault #308

dagle opened this issue Jan 30, 2023 · 0 comments

Comments

@dagle
Copy link

dagle commented Jan 30, 2023

Calling _resolve(true) with luajit 2.1.0beta3 seems to make luajit to segfault for some components. It seems to be _parent that causes problem, and calling _resolve(false) on a _parent object causes a segfault (haven't been able to find anything else causing this). This how ever doesn't seem to happen for all libraries. But I found at least 10 typelibs on my system that caused the problems.

local lgi = require 'lgi'
local gmime = lgi.require('GMime', "3.0")

gmime.init()
gmime:_resolve(true)

while true do
end

Running gdb I get: undefined symbol: g_mime_object_type_registry_shutdown. That function is only used during shutdown of gmime and shouldn't be called at all, feel like something wrong is happening before that.

I tried using luajit 2.0.5 and instead of a crash, I get a infinite loop instead.

With lua 5.4 the code works correctly and loads everything correctly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant