Skip to content

Commit

Permalink
autofarm: fix GCC warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
lethosor committed Jan 19, 2020
1 parent bb9bc4e commit d4d083d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugins/autofarm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,7 @@ DFhackCExport command_result plugin_enable(color_ostream &out, bool enable)
static command_result setThresholds(color_ostream& out, vector<string> & parameters)
{
int val = atoi(parameters[1].c_str());
for (int i = 2; i < parameters.size(); i++)
for (size_t i = 2; i < parameters.size(); i++)
{
string id = parameters[i];
transform(id.begin(), id.end(), id.begin(), ::toupper);
Expand Down Expand Up @@ -426,7 +426,7 @@ static command_result autofarm(color_ostream &out, vector <string> & parameters)
autofarmInstance->setDefault(atoi(parameters[1].c_str()));
else if (parameters.size() >= 3 && parameters[0] == "threshold")
return setThresholds(out, parameters);
else if (parameters.size() == 0 || parameters.size() == 1 && parameters[0] == "status")
else if (parameters.size() == 0 || (parameters.size() == 1 && parameters[0] == "status"))
autofarmInstance->status(out);
else
return CR_WRONG_USAGE;
Expand Down

0 comments on commit d4d083d

Please sign in to comment.