On Tue, Jun 13, 2017 at 9:10 AM, <kowlsd3pw...@yahoo.co.jp> wrote: > Nobody will put big files, but there are logic defects > > int size; > > file size is INT_MAX + 1 then size is negative(INT_MIN) >
Actually, that's not guaranteed. The C standard guarantees overflow/underflow behaviour only for unsigned integers. For signed integers, over/underflow have undefined results. (However, every machine i have ever tested this on does wrap predictably for signed integers.) -- ----- stephan beal http://wanderinghorse.net/home/stephan/ "Freedom is sloppy. But since tyranny's the only guaranteed byproduct of those who insist on a perfect world, freedom will have to do." -- Bigby Wolf
_______________________________________________ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users