Skip to content

Commit

Permalink
Use luaFatal() if luaL_dofile() explodes.
Browse files Browse the repository at this point in the history
  • Loading branch information
icculus committed Dec 24, 2013
1 parent 39b43c6 commit c88cba1
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions 1pass.c
Expand Up @@ -366,12 +366,7 @@ static int initLua(const int argc, char **argv)

// Transfer control to Lua...
if (luaL_dofile(luaState, "1pass.lua") != 0)
{
const char *msg = lua_tostring(luaState, -1);
fprintf(stderr, "1pass.lua didn't run: %s\n", msg);
lua_pop(luaState, 1);
return 0;
} // if
luaFatal(luaState);

return 1;
} // initLua
Expand Down

0 comments on commit c88cba1

Please sign in to comment.