(decode_num): simplify expression.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Signed-off-by: Yury V. Zaytsev <yury@shurup.com>
This commit is contained in:
Andrew Borodin 2024-10-10 21:12:21 +03:00 committed by Yury V. Zaytsev
parent 773bb6f60b
commit f4740bf0b9

View File

@ -257,7 +257,7 @@ decode_num (uintmax_t *num, const char *arg, uintmax_t maxval)
gboolean overflow;
*num = stoint (arg, &arg_lim, &overflow, 0, maxval);
return (((arg_lim == arg ? 1 : 0) | (*arg_lim != '\0') | (overflow ? 1 : 0)) == 0);
return !(arg_lim == arg || *arg_lim != '\0' || overflow);
}
/* --------------------------------------------------------------------------------------------- */