]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
fix a signed/unsigned comparison
authorRoger Dingledine <arma@torproject.org>
Tue, 12 Oct 2004 18:32:34 +0000 (18:32 +0000)
committerRoger Dingledine <arma@torproject.org>
Tue, 12 Oct 2004 18:32:34 +0000 (18:32 +0000)
svn:r2446

src/or/routerparse.c

index 9d999e8841cd95d94ace30b70500db9cb10c4418..4ae22224562f6120e4834df060741bdba31cfec0 100644 (file)
@@ -1445,7 +1445,7 @@ int tor_version_as_new_as(const char *platform, const char *cutoff) {
   start = (char *)eat_whitespace(platform+3);
   if (!*start) return 0;
   s = (char *)find_whitespace(start); /* also finds '\0', which is fine */
-  if(s-start+1 >= sizeof(tmp)) /* too big, no */
+  if((size_t)(s-start+1) >= sizeof(tmp)) /* too big, no */
     return 0;
   strlcpy(tmp, start, s-start+1);