[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: LUA_ERRSYNTAX with luaL_dofile
- From: cynthia powers <powcyn@...>
- Date: Sun, 1 Nov 2009 15:49:19 -0500
Hi,
I am very new to lua. and I am trying a c-calling-lua setup. I get an error : status = 3(LUA_ERRSYNTAX) to the luaL_dofile call below. WHat am I doing wrong? Any help is appreciated.
int run_lua_block ()
{
lua_State *L;
L = lua_open();
openlualibs(L);
registerMyFunction (L);
lua_settop (L,0);
int status = luaL_dofile (L, "myfile.lua");
lua_close(L);
return status;
}
Thanks
cynthia.