diff options
Diffstat (limited to 'networking/wget.c')
-rw-r--r-- | networking/wget.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/networking/wget.c b/networking/wget.c index 5b73b93..97f4a8f 100644 --- a/networking/wget.c +++ b/networking/wget.c @@ -282,8 +282,10 @@ static char *gethdr(char *buf, size_t bufsiz, FILE *fp /*, int *istrunc*/) return NULL; /* convert the header name to lower case */ - for (s = buf; isalnum(*s) || *s == '-' || *s == '.'; ++s) - *s = tolower(*s); + for (s = buf; isalnum(*s) || *s == '-' || *s == '.'; ++s) { + /* tolower for "A-Z", no-op for "0-9a-z-." */ + *s = (*s | 0x20); + } /* verify we are at the end of the header name */ if (*s != ':') |