lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


2011/12/29 Gaspard Bucher <gaspard@teti.ch>:
> Hi Roberto, thanks for the feedback. This means that my problem is
> even more strange. The crash happens whatever C function I call. Here
> is the gdb dump:

Hi,

I'm not sure about your error but in past I've got a problem with weak
keys table. The problem was that Lua can finalize the object without
removing it from the table. The object will be removed only in the
next collection cycle and it is therefore possible that you can access
an object that is already finalized.

The other problem that happened to me was that Lua does not ensure the
order of finalization. Thus the userdata a can depend on b through a
fenv table and still Lua can finalize b *before* finalizing a. You
should therefore ensure that the object can be finalized in any order
even if there are cross dependencies.

I don't know if this is helpful but in past I've got problem similar
to your because of that.

Otherwise I recommend to compile the application with debugging
symbols and using gdb and valgrind.

Francesco