Portability - Ubuntu 8
- Changed unsigned int to size_t for std::string::npos comparison. - Removed validBuiltinCommand function that is not used.
This commit is contained in:
@@ -342,18 +342,6 @@ static bool validCommand (std::string& input)
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
|
||||||
static bool validBuiltinCommand (std::string& input)
|
|
||||||
{
|
|
||||||
std::string copy = input;
|
|
||||||
guess ("command", commands, copy);
|
|
||||||
if (copy == "")
|
|
||||||
return false;
|
|
||||||
|
|
||||||
input = copy;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
static bool validSubstitution (
|
static bool validSubstitution (
|
||||||
std::string& input,
|
std::string& input,
|
||||||
@@ -509,7 +497,7 @@ void loadCustomReports (Config& conf)
|
|||||||
if (i->substr (0, 7) == "report.")
|
if (i->substr (0, 7) == "report.")
|
||||||
{
|
{
|
||||||
std::string report = i->substr (7, std::string::npos);
|
std::string report = i->substr (7, std::string::npos);
|
||||||
unsigned int columns = report.find (".columns");
|
size_t columns = report.find (".columns");
|
||||||
if (columns != std::string::npos)
|
if (columns != std::string::npos)
|
||||||
{
|
{
|
||||||
report = report.substr (0, columns);
|
report = report.substr (0, columns);
|
||||||
|
|||||||
Reference in New Issue
Block a user