Module: sip-router Branch: master Commit: 7d6dc390bac2b49615444bcbad74cd39f3c82302 URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=7d6dc390...
Author: Daniel-Constantin Mierla miconda@gmail.com Committer: Daniel-Constantin Mierla miconda@gmail.com Date: Fri Dec 6 19:03:08 2013 +0100
tls: removed unsigned int comparison with <0
---
modules/tls/tls_config.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/modules/tls/tls_config.c b/modules/tls/tls_config.c index f05c211..7937876 100644 --- a/modules/tls/tls_config.c +++ b/modules/tls/tls_config.c @@ -84,7 +84,7 @@ static int parse_ipv4(struct ip_addr* ip, cfg_token_t* token, ip->len = 4;
if (str2int(&token->val, &v) < 0) goto err; - if (v < 0 || v > 255) goto err; + if (v > 255) goto err;
ip->u.addr[0] = v;
@@ -97,7 +97,7 @@ static int parse_ipv4(struct ip_addr* ip, cfg_token_t* token, if (ret < 0) return -1; if (ret > 0 || t.type != CFG_TOKEN_ALPHA) goto err; if (str2int(&t.val, &v) < 0) goto err; - if (v < 0 || v > 255) goto err; + if (v > 255) goto err; ip->u.addr[i] = v; }