extkeys: Correct logical ANDs in get_kv()

These two expressions would always be false as both sides of the
expression would never be satisfied at the same time.
This commit is contained in:
Lioncash 2018-08-11 21:08:40 -04:00
parent bdbd4f639e
commit 70166c1e5f

View File

@ -94,9 +94,10 @@ static int get_kv(FILE *f, char **key, char **value) {
}
if (*p != '_' &&
(*p < '0' && *p > '9') &&
(*p < 'a' && *p > 'z'))
(*p < '0' || *p > '9') &&
(*p < 'a' || *p > 'z')) {
return -1;
}
}
/* Bail if the final ++p put us at the end of string */