Fixed warnings in ManualBindings.
This commit is contained in:
parent
d950c8346f
commit
06da2c86b4
@ -37,7 +37,7 @@
|
|||||||
/****************************
|
/****************************
|
||||||
* Better error reporting for Lua
|
* Better error reporting for Lua
|
||||||
**/
|
**/
|
||||||
int tolua_do_error(lua_State* L, const char * a_pMsg, tolua_Error * a_pToLuaError)
|
static int tolua_do_error(lua_State* L, const char * a_pMsg, tolua_Error * a_pToLuaError)
|
||||||
{
|
{
|
||||||
// Retrieve current function name
|
// Retrieve current function name
|
||||||
lua_Debug entry;
|
lua_Debug entry;
|
||||||
@ -57,7 +57,7 @@ int tolua_do_error(lua_State* L, const char * a_pMsg, tolua_Error * a_pToLuaErro
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
int lua_do_error(lua_State* L, const char * a_pFormat, ...)
|
static int lua_do_error(lua_State* L, const char * a_pFormat, ...)
|
||||||
{
|
{
|
||||||
// Retrieve current function name
|
// Retrieve current function name
|
||||||
lua_Debug entry;
|
lua_Debug entry;
|
||||||
@ -235,7 +235,7 @@ static int tolua_Base64Decode(lua_State * tolua_S)
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
cPluginLua * GetLuaPlugin(lua_State * L)
|
static cPluginLua * GetLuaPlugin(lua_State * L)
|
||||||
{
|
{
|
||||||
// Get the plugin identification out of LuaState:
|
// Get the plugin identification out of LuaState:
|
||||||
lua_getglobal(L, LUA_PLUGIN_INSTANCE_VAR_NAME);
|
lua_getglobal(L, LUA_PLUGIN_INSTANCE_VAR_NAME);
|
||||||
@ -1782,7 +1782,7 @@ static int tolua_cPlayer_GetGroups(lua_State* tolua_S)
|
|||||||
|
|
||||||
const cPlayer::GroupList & AllGroups = self->GetGroups();
|
const cPlayer::GroupList & AllGroups = self->GetGroups();
|
||||||
|
|
||||||
lua_createtable(tolua_S, AllGroups.size(), 0);
|
lua_createtable(tolua_S, (int)AllGroups.size(), 0);
|
||||||
int newTable = lua_gettop(tolua_S);
|
int newTable = lua_gettop(tolua_S);
|
||||||
int index = 1;
|
int index = 1;
|
||||||
cPlayer::GroupList::const_iterator iter = AllGroups.begin();
|
cPlayer::GroupList::const_iterator iter = AllGroups.begin();
|
||||||
@ -1807,14 +1807,14 @@ static int tolua_cPlayer_GetResolvedPermissions(lua_State* tolua_S)
|
|||||||
|
|
||||||
cPlayer::StringList AllPermissions = self->GetResolvedPermissions();
|
cPlayer::StringList AllPermissions = self->GetResolvedPermissions();
|
||||||
|
|
||||||
lua_createtable(tolua_S, AllPermissions.size(), 0);
|
lua_createtable(tolua_S, (int)AllPermissions.size(), 0);
|
||||||
int newTable = lua_gettop(tolua_S);
|
int newTable = lua_gettop(tolua_S);
|
||||||
int index = 1;
|
int index = 1;
|
||||||
cPlayer::StringList::iterator iter = AllPermissions.begin();
|
cPlayer::StringList::iterator iter = AllPermissions.begin();
|
||||||
while (iter != AllPermissions.end())
|
while (iter != AllPermissions.end())
|
||||||
{
|
{
|
||||||
std::string & Permission = *iter;
|
std::string & Permission = *iter;
|
||||||
tolua_pushstring( tolua_S, Permission.c_str() );
|
lua_pushlstring(tolua_S, Permission.c_str(), Permission.length());
|
||||||
lua_rawseti(tolua_S, newTable, index);
|
lua_rawseti(tolua_S, newTable, index);
|
||||||
++iter;
|
++iter;
|
||||||
++index;
|
++index;
|
||||||
@ -2080,7 +2080,7 @@ static int tolua_cWebAdmin_GetPlugins(lua_State * tolua_S)
|
|||||||
|
|
||||||
const cWebAdmin::PluginList & AllPlugins = self->GetPlugins();
|
const cWebAdmin::PluginList & AllPlugins = self->GetPlugins();
|
||||||
|
|
||||||
lua_createtable(tolua_S, AllPlugins.size(), 0);
|
lua_createtable(tolua_S, (int)AllPlugins.size(), 0);
|
||||||
int newTable = lua_gettop(tolua_S);
|
int newTable = lua_gettop(tolua_S);
|
||||||
int index = 1;
|
int index = 1;
|
||||||
cWebAdmin::PluginList::const_iterator iter = AllPlugins.begin();
|
cWebAdmin::PluginList::const_iterator iter = AllPlugins.begin();
|
||||||
|
Loading…
Reference in New Issue
Block a user