From: Todd C. Miller Date: Thu, 20 Jan 2000 16:15:41 +0000 (+0000) Subject: Cast ULONG_MAX to unsigned long long when comparing to an unsigned long long X-Git-Tag: SUDO_1_6_2~6 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6e5f1c729acd992457227877e5cbb7689b0e5b2c;p=sudo Cast ULONG_MAX to unsigned long long when comparing to an unsigned long long value. --- diff --git a/snprintf.c b/snprintf.c index 67bf7587e..e3bde41ae 100644 --- a/snprintf.c +++ b/snprintf.c @@ -219,7 +219,7 @@ __uqtoa(val, endp, base, octzero, xdigs) /* quick test for small values; __ultoa is typically much faster */ /* (perhaps instead we should run until small, then call __ultoa?) */ - if (val <= ULONG_MAX) + if (val <= (unsigned long long)ULONG_MAX) return (__ultoa((unsigned long)val, endp, base, octzero, xdigs)); switch (base) { case 10: