Shifts left and right by 32 were tripping a gcc warning (fatal with
authorsimon <simon@cda61777-01e9-0310-a592-d414129be87e>
Tue, 15 Aug 2006 20:29:02 +0000 (20:29 +0000)
committersimon <simon@cda61777-01e9-0310-a592-d414129be87e>
Tue, 15 Aug 2006 20:29:02 +0000 (20:29 +0000)
-Werror, of course) about shifting by more than the range of a data
type. They only appeared in `if' statements testing sizeof(off_t),
but gcc warns even when the code is unreachable. I've removed the
conditional code (the general case should still work even on 32-bit
machines), and hacked each shift by 32 into a pair of shifts by 16.

Note that the gcc warning is not just a helpful indication that you
may be using the wrong data type; it's actually pointing out ANSI-
undefined behaviour in shifting a signed integer beyond the size of
its type.

git-svn-id: svn://svn.tartarus.org/sgt/putty@6789 cda61777-01e9-0310-a592-d414129be87e


No differences found