jzrake/lunar — Issue #2: invalid read on Mac OS 10.6
Author: jzrake
Created: 2012-01-29 15:43:36+00:00
State: open

Valgrind reports an invalid read when loading shared object files. This seems to be independent of any lunar functions. Compile flags are:

export CFLAGS = -Wall -O2 -fPIC
export SO = libtool -dynamic -lm

==25058== Invalid read of size 8
==25058== at 0x7FFFFFE00A71: ???
==25058== by 0x100016692: luaL_addlstring (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x100016707: luaL_addvalue (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x10001F192: ll_require (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x100008079: luaD_precall (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x1000082DB: luaD_call (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x10000746B: luaD_rawrunprotected (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x1000074D2: luaD_pcall (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x10000348B: lua_pcallk (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x1000016A3: docall (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x1000021E5: pmain (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x100008079: luaD_precall (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== Address 0x10032e388 is 232 bytes inside a block of size 238 alloc'd
==25058== at 0x100043679: malloc (vg_replace_malloc.c:266)
==25058== by 0x10004380A: realloc (vg_replace_malloc.c:635)
==25058== by 0x10000C07C: luaM_realloc_ (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x100009CB4: luaC_newobj (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x10001032C: luaS_newlstr (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x10000309A: lua_pushlstring (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x100014825: luaL_pushresult (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x10001F6A6: searchpath (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x10001FC0E: searcher_Lua (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x100008079: luaD_precall (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x1000082DB: luaD_call (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)
==25058== by 0x1000035AA: lua_callk (in /Users/li_wong3/Downloads/lua-5.2.0/bin/lua)