CrackedP0t / LuaNoise

LibNoise bound to Lua

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

LuaJIT but not Lua segfaults when code from noiseutils is run

CrackedP0t opened this issue · comments

For example, this will segfault:

noise = require("noise")
noisemap = noise.NoiseMap()

Luajit and Fedora 23.
tutorial_2 OK
tutorial_3 segments at renderer:Render()
tutorial_4 segments at renderer:SetLightContrast(3)
tutorial_5 segments at quiting the program
tutorial_6 segments at quiting the program
tutorial_7 segments at quiting the program
tutorial_8 segments at renderer:Render()

@padicao2010 How'd you figure this out?

@CrackedP0t Easy. I've added some print statements in the source codes, in order to find out where the program exit abnormally.

Fixed in 2d77a94. The GC metamethod wasn't returning a value, and apparently Lua was OK with it but LuaJIT wasn't.