diff options
author | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-02-01 10:12:54 +0100 |
---|---|---|
committer | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-02-01 10:12:54 +0100 |
commit | bb49f0e021fb1fbefad44d944233fb1cf72c495c (patch) | |
tree | ebb0f2b40a3987eddf126c368237c0c60e4e6518 /source/cLuaCommandBinder.cpp | |
parent | Fixed a sigsegv on *nix (cFile double-closing files) (diff) | |
download | cuberite-bb49f0e021fb1fbefad44d944233fb1cf72c495c.tar cuberite-bb49f0e021fb1fbefad44d944233fb1cf72c495c.tar.gz cuberite-bb49f0e021fb1fbefad44d944233fb1cf72c495c.tar.bz2 cuberite-bb49f0e021fb1fbefad44d944233fb1cf72c495c.tar.lz cuberite-bb49f0e021fb1fbefad44d944233fb1cf72c495c.tar.xz cuberite-bb49f0e021fb1fbefad44d944233fb1cf72c495c.tar.zst cuberite-bb49f0e021fb1fbefad44d944233fb1cf72c495c.zip |
Diffstat (limited to '')
-rw-r--r-- | source/cLuaCommandBinder.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/source/cLuaCommandBinder.cpp b/source/cLuaCommandBinder.cpp index 5ed3515ca..2e1d504b1 100644 --- a/source/cLuaCommandBinder.cpp +++ b/source/cLuaCommandBinder.cpp @@ -11,7 +11,6 @@ -extern std::vector<std::string> StringSplit(std::string str, std::string delim);
extern bool report_errors(lua_State* lua, int status);
cLuaCommandBinder::cLuaCommandBinder()
@@ -58,8 +57,11 @@ bool cLuaCommandBinder::BindCommand( const std::string & a_Command, const std::s bool cLuaCommandBinder::HandleCommand( const std::string & a_Command, cPlayer* a_Player )
{
- std::vector<std::string> Split = StringSplit( a_Command, " ");
- if( Split.size() == 0 ) return false;
+ AStringVector Split = StringSplit(a_Command, " ");
+ if (Split.size() == 0)
+ {
+ return false;
+ }
CommandMap::iterator FoundCommand = m_BoundCommands.find( Split[0] );
if( FoundCommand != m_BoundCommands.end() )
|