aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWolfgang Draxinger <Wolfgang.Draxinger@physik.uni-muenchen.de>2013-10-02 17:26:11 +0200
committerWolfgang Draxinger <Wolfgang.Draxinger@physik.uni-muenchen.de>2013-10-02 17:26:11 +0200
commit65930003e56b64afdde64cd9597e55b21d08b7c3 (patch)
tree54bdcb0d5e156258025169e3f8cdc289a1efcf16
parent4744fdf082ad71334cd075d1fce49dcf7556df3e (diff)
downloadlitheweb-65930003e56b64afdde64cd9597e55b21d08b7c3.tar.gz
litheweb-65930003e56b64afdde64cd9597e55b21d08b7c3.tar.bz2
signed-unsigned comparisions fixed
-rw-r--r--picohttp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/picohttp.c b/picohttp.c
index 51f66ec..d813a3e 100644
--- a/picohttp.c
+++ b/picohttp.c
@@ -839,8 +839,8 @@ static void picohttpProcessHeaderAuthorization(
char *c;
for(c = user_password; *c && ':' != *c; c++);
if( !*c
- || (c - user_password >= user_password_max_len)
- || (c - user_password > req->query.auth->username_maxlen)
+ || ((size_t)(c - user_password) >= user_password_max_len)
+ || ((size_t)(c - user_password) > req->query.auth->username_maxlen)
|| (strlen(c+1) > req->query.auth->pwresponse_maxlen) ) {
/* no colon found, or colon is last character in string
* or username part doesn't fit into auth.username field