[Bug 1192] warning: comparison between signed and unsigned

bugzilla-daemon at mindrot.org
Mon, 22 May 2006 03:55:17 -0000

------- Comment #2 from dtucker at zip.com.au  2006-05-22 13:55 -------
(From update of attachment 1142)
>-	size_t result;
>+	off_t i, amt, result, statbytes;

I don't think that's the right way forward since later there is:

        result = atomicio(read, fd, bp->buf, amt)

and atomicio now returns a size_t.

Instead, I think we should be changing the progressmeter interface to
u_int64_t from off_t (since ultimately, the size it operates on is
fixed at 64 bits by the packet format of the sftp spec).  This would
change "amt" and also fix the warning.

There's an old bug for this (#842) but I suspect the diff will need
some tweaking.