mirror of
https://github.com/ctruLua/ctruLua.git
synced 2025-10-27 16:39:29 +00:00
Enhanced the error message for "luaL_dofile(L, BOOTFILE)"
This commit is contained in:
parent
b772a42d28
commit
df4ce7ba14
1 changed files with 2 additions and 2 deletions
|
|
@ -12,7 +12,7 @@ int load_ctr_lib(lua_State *L);
|
||||||
void unload_font_lib();
|
void unload_font_lib();
|
||||||
|
|
||||||
// Display an error
|
// Display an error
|
||||||
void error(char *error) {
|
void error(const char *error) {
|
||||||
gfxInitDefault();
|
gfxInitDefault();
|
||||||
|
|
||||||
consoleInit(GFX_TOP, NULL);
|
consoleInit(GFX_TOP, NULL);
|
||||||
|
|
@ -46,7 +46,7 @@ int main() {
|
||||||
load_ctr_lib(L);
|
load_ctr_lib(L);
|
||||||
|
|
||||||
// Do the actual thing
|
// Do the actual thing
|
||||||
if (luaL_dofile(L, BOOT_FILE)) error("Can't open the boot file "BOOT_FILE);
|
if (luaL_dofile(L, BOOT_FILE)) error(luaL_checkstring(L, -1));
|
||||||
|
|
||||||
// Unload current font
|
// Unload current font
|
||||||
unload_font_lib();
|
unload_font_lib();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue