summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2001-12-03 12:57:45 +0000
committerDaniel Stenberg <daniel@haxx.se>2001-12-03 12:57:45 +0000
commit7493db2338a669261ed82cce834446b4c3b08bd5 (patch)
tree490af0322265b605e906e14b9f2a977f6bd44ffd
parentc3ad019c991c5c544d6960bf1169c413c81cbf93 (diff)
downloadcurl-7493db2338a669261ed82cce834446b4c3b08bd5.tar.gz
Eric nailed a but in strnequal() for macintosh
-rw-r--r--lib/strequal.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/strequal.c b/lib/strequal.c
index 6859e26bd..df5d4f14b 100644
--- a/lib/strequal.c
+++ b/lib/strequal.c
@@ -63,6 +63,9 @@ int curl_strnequal(const char *first, const char *second, size_t max)
first++;
second++;
}
+ if(0 == max)
+ return 1; /* they are equal this far */
+
return toupper(*first) == toupper(*second);
#endif
}