- portable ctype (http://www.netbsd.org/cgi-bin/query-pr-single.pl?number=34632)
[m6w6/ext-http] / http_date_api.c
index ba6ef45ef13321838d508af622bf55a342aba464..10f3463a437c8efd2ab5cee7636f8c22ba2815f9 100644 (file)
@@ -204,11 +204,11 @@ static inline time_t parse_date(const char *date)
        while (*date && (part < 6)) {
                int found = 0;
 
-               while (*date && !isalnum(*date)) {
+               while (*date && !HTTP_IS_CTYPE(alnum, *date)) {
                        date++;
                }
 
-               if (isalpha(*date)) {
+               if (HTTP_IS_CTYPE(alpha, *date)) {
                        /* a name coming up */
                        char buf[32] = "";
                        size_t len;
@@ -242,7 +242,7 @@ static inline time_t parse_date(const char *date)
                        }
                        date += len;
                }
-               else if (isdigit(*date)) {
+               else if (HTTP_IS_CTYPE(digit, *date)) {
                        /* a digit */
                        int val;
                        char *end;