mirror of
https://github.com/d0k3/GodMode9.git
synced 2025-06-18 17:05:49 -04:00
fix a few cases of improper varg usage in luaL_error
This commit is contained in:
parent
9ae4351bce
commit
cf1cb1cfc5
@ -122,7 +122,7 @@ static int internalfs_mkdir(lua_State* L) {
|
||||
|
||||
FRESULT res = fvx_rmkdir(path);
|
||||
if (res != FR_OK) {
|
||||
return luaL_error(L, "could not mkdir (%d)", path, res);
|
||||
return luaL_error(L, "could not mkdir %s (%d)", path, res);
|
||||
}
|
||||
|
||||
return 0;
|
||||
@ -467,7 +467,7 @@ static int internalfs_make_dummy_file(lua_State* L) {
|
||||
CheckWritePermissionsLuaError(L, path);
|
||||
|
||||
if (!(FileCreateDummy(path, NULL, size))) {
|
||||
return luaL_error(L, "FileCreateDummy failed on %s");
|
||||
return luaL_error(L, "FileCreateDummy failed on %s", path);
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
@ -35,7 +35,7 @@ static inline void CheckLuaArgCount(lua_State* L, int argcount, const char* cmd)
|
||||
static inline bool CheckLuaArgCountPlusExtra(lua_State* L, int argcount, const char* cmd) {
|
||||
int args = lua_gettop(L);
|
||||
if (args != argcount && args != argcount + 1) {
|
||||
luaL_error(L, "bad number of arguments passed to '%s' (expected %d, got %d or %d)", cmd, argcount, args);
|
||||
luaL_error(L, "bad number of arguments passed to '%s' (expected %d or %d, got %d)", cmd, argcount, argcount + 1, args);
|
||||
}
|
||||
return args == argcount + 1;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user