]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
fixed a "comparison between signed and unsigned" warning
authorDaniel Stenberg <daniel@haxx.se>
Thu, 26 Feb 2004 22:19:20 +0000 (22:19 +0000)
committerDaniel Stenberg <daniel@haxx.se>
Thu, 26 Feb 2004 22:19:20 +0000 (22:19 +0000)
ares/ares_init.c

index 519d9552474898ed4c354f56b4f8a7b875413fd2..444fd8a66aa9db3c4d862c311debe5e15c0c3fd1 100644 (file)
@@ -784,7 +784,7 @@ static char *try_config(char *s, const char *opt)
 static const char *try_option(const char *p, const char *q, const char *opt)
 {
   size_t len = strlen(opt);
-  return (q - p > len && strncmp(p, opt, len) == 0) ? p + len : NULL;
+  return ((size_t)(q - p) > len && !strncmp(p, opt, len)) ? &p[len] : NULL;
 }
 
 static int ip_addr(const char *s, int len, struct in_addr *addr)