Re: Somtimes the odds are stacked against you.
I discovered this in some code that was fine on 32-bit Windows and 64-bit Linux, but had a fault in one mode on 32-bit Linux.
Turned out to be the same sort of thing where someone in the Linux world decided to be "helpful" and limit floats converted to 32-bit ints that went outside of the range, except here that was an intended and correct thing to do (i.e. convert to integer possibly above 32 bits and let it be truncated to 32). Fix was to covert to 64-bit int then cast as 32-bit so it worked the same on all platforms.