lua-users home
lua-l archive

Re: Another userdata question

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


 I just realized there's a bug in the code I submitted. Where I originally
wrote:
> button = lua_newuserdata(L,sizeof(OSLIB_OBJECT));
> memset(button,0,sizeof(OSLIB_OBJECT));
> *button = createObject(LIB_GRAPHICS_BUTTON,name);
should be:
	button = lua_newuserdata(L,sizeof(OSLIB_OBJECT *));
	*button = createObject(LIB_GRAPHICS_BUTTON,name);
 The rest of the code should be okay.
 -spc (Sorry about that)

AltStyle によって変換されたページ (->オリジナル) /