aboutsummaryrefslogtreecommitdiffhomepage
path: root/builtin_test.cpp
diff options
context:
space:
mode:
authorGravatar ridiculousfish <corydoras@ridiculousfish.com>2014-05-31 13:46:28 -0700
committerGravatar ridiculousfish <corydoras@ridiculousfish.com>2014-05-31 13:46:28 -0700
commitce4081af934e37876f3b6e641935364b4d8bbfaf (patch)
tree08e8a7747af26142127bf1d04e865165a61c6664 /builtin_test.cpp
parent32f5edc9c5d8d08cc57abe84c804e87b898513e9 (diff)
Fix some warnings in Linux build
Diffstat (limited to 'builtin_test.cpp')
-rw-r--r--builtin_test.cpp4
1 files changed, 0 insertions, 4 deletions
diff --git a/builtin_test.cpp b/builtin_test.cpp
index 0d16823a..23369628 100644
--- a/builtin_test.cpp
+++ b/builtin_test.cpp
@@ -646,13 +646,11 @@ expression *test_parser::parse_args(const wcstring_list_t &args, wcstring &err)
expression *result = parser.parse_expression(0, (unsigned int)args.size());
/* Handle errors */
- bool errored = false;
for (size_t i = 0; i < parser.errors.size(); i++)
{
err.append(L"test: ");
err.append(parser.errors.at(i));
err.push_back(L'\n');
- errored = true;
// For now we only show the first error
break;
}
@@ -667,14 +665,12 @@ expression *test_parser::parse_args(const wcstring_list_t &args, wcstring &err)
{
append_format(err, L"test: unexpected argument at index %lu: '%ls'\n", (unsigned long)result->range.end, args.at(result->range.end).c_str());
}
- errored = true;
delete result;
result = NULL;
}
}
-
return result;
}