L'\0' is not a pointer, don't compare it to one

Compare to NULL instead. Comparison with original code
shows this is what is intended.
This commit is contained in:
ridiculousfish 2016-11-20 00:30:55 -08:00
parent 52d1b6b97d
commit b86b84e2a9

View file

@ -492,7 +492,7 @@ void parse_util_get_parameter_info(const wcstring &cmd, const size_t pos, wchar_
bool finished = cmdlen != 0;
if (finished) {
finished = (quote == NULL);
if (finished && wcschr(L" \t\n\r", cmd_tmp[cmdlen - 1]) != L'\0') {
if (finished && wcschr(L" \t\n\r", cmd_tmp[cmdlen - 1]) != NULL) {
finished = cmdlen > 1 && cmd_tmp[cmdlen - 2] == L'\\';
}
}