[or-cvs] r13624: Suppress signed/unsigned comparison warnings in buffers.c (in tor/trunk: . src/or)

nickm at seul.org nickm at seul.org
Wed Feb 20 21:57:48 UTC 2008


Author: nickm
Date: 2008-02-20 16:57:48 -0500 (Wed, 20 Feb 2008)
New Revision: 13624

Modified:
   tor/trunk/
   tor/trunk/src/or/buffers.c
Log:
 r18267 at catbus:  nickm | 2008-02-20 16:57:45 -0500
 Suppress signed/unsigned comparison warnings in buffers.c



Property changes on: tor/trunk
___________________________________________________________________
 svk:merge ticket from /tor/trunk [r18267] on 8246c3cf-6607-4228-993b-4d95d33730f1

Modified: tor/trunk/src/or/buffers.c
===================================================================
--- tor/trunk/src/or/buffers.c	2008-02-20 17:48:39 UTC (rev 13623)
+++ tor/trunk/src/or/buffers.c	2008-02-20 21:57:48 UTC (rev 13624)
@@ -1021,7 +1021,7 @@
   int pos;
   tor_assert(out);
   if (out->chunk)
-    tor_assert(out->pos < out->chunk->datalen);
+    tor_assert(out->pos < (off_t)out->chunk->datalen);
   pos = out->pos;
   for (chunk = out->chunk; chunk; chunk = chunk->next) {
     char *cp = memchr(chunk->data+pos, ch, chunk->datalen-pos);
@@ -1043,7 +1043,7 @@
 buf_pos_inc(buf_pos_t *pos)
 {
   ++pos->pos;
-  if (pos->pos == pos->chunk->datalen) {
+  if (pos->pos == (off_t)pos->chunk->datalen) {
     if (!pos->chunk->next)
       return -1;
     pos->chunk_pos += pos->chunk->datalen;



More information about the tor-commits mailing list