diff options
Diffstat (limited to 'src/lib/libc/net/ruserok.c')
-rw-r--r-- | src/lib/libc/net/ruserok.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/lib/libc/net/ruserok.c b/src/lib/libc/net/ruserok.c index 46fba4beb2..21646c156b 100644 --- a/src/lib/libc/net/ruserok.c +++ b/src/lib/libc/net/ruserok.c | |||
@@ -214,9 +214,10 @@ __ivaliduser_sa(FILE *hostf, struct sockaddr *raddr, socklen_t salen, | |||
214 | if (*p == '#') | 214 | if (*p == '#') |
215 | continue; | 215 | continue; |
216 | while (p < buf + buflen && *p != '\n' && *p != ' ' && *p != '\t') { | 216 | while (p < buf + buflen && *p != '\n' && *p != ' ' && *p != '\t') { |
217 | if (!isprint(*p)) | 217 | if (!isprint((unsigned char)*p)) |
218 | goto bail; | 218 | goto bail; |
219 | *p = isupper(*p) ? tolower(*p) : *p; | 219 | *p = isupper((unsigned char)*p) ? |
220 | tolower((unsigned char)*p) : *p; | ||
220 | p++; | 221 | p++; |
221 | } | 222 | } |
222 | if (p >= buf + buflen) | 223 | if (p >= buf + buflen) |
@@ -230,7 +231,7 @@ __ivaliduser_sa(FILE *hostf, struct sockaddr *raddr, socklen_t salen, | |||
230 | user = p; | 231 | user = p; |
231 | while (p < buf + buflen && *p != '\n' && *p != ' ' && | 232 | while (p < buf + buflen && *p != '\n' && *p != ' ' && |
232 | *p != '\t') { | 233 | *p != '\t') { |
233 | if (!isprint(*p)) | 234 | if (!isprint((unsigned char)*p)) |
234 | goto bail; | 235 | goto bail; |
235 | p++; | 236 | p++; |
236 | } | 237 | } |