From: Todd C. Miller Date: Tue, 26 Oct 2004 22:17:15 +0000 (+0000) Subject: Add casts to unsigned char for isspace() to quiet a gcc warning. X-Git-Tag: SUDO_1_7_0~861 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=0de1515d0692279460588787abea32efe5eaac14;p=sudo Add casts to unsigned char for isspace() to quiet a gcc warning. --- diff --git a/ldap.c b/ldap.c index ba52bd6aa..359396656 100644 --- a/ldap.c +++ b/ldap.c @@ -505,23 +505,23 @@ sudo_ldap_read_config() if (!*c) continue; /* incomplete last line */ /* skip whitespace before keyword */ - while (isspace(*c)) c++; + while (isspace((unsigned char)*c)) c++; keyword=c; /* properly terminate keyword string */ - while (*c && !isspace(*c)) c++; + while (*c && !isspace((unsigned char)*c)) c++; if (*c) { *c='\0'; /* terminate keyword */ c++; } /* skip whitespace before value */ - while (isspace(*c)) c++; + while (isspace((unsigned char)*c)) c++; value=c; /* trim whitespace after value */ while (*c) c++; /* wind to end */ - while (--c > value && isspace(*c)) *c='\0'; + while (--c > value && isspace((unsigned char)*c)) *c='\0'; /* The following macros make the code much more readable */