Parser: Fix segfault in command extraction

这个提交包含在:
Albert S. 2018-11-05 10:46:06 +01:00
父节点 e863b5261b
当前提交 538d9e8b2d
共有 1 个文件被更改,包括 4 次插入1 次删除

查看文件

@ -71,7 +71,10 @@ std::string Parser::extractCommand(std::string cmdname, std::string content) con
if(std::regex_match(content, match, reg))
{
return match.str(2);
if(match.size() > 1)
{
return match.str(2);
}
}
return "";
}