On 1/7/23 1:45 PM, Martin Schulte wrote:
Hello!

Am Sat, 07 Jan 2023 19:08:06 +0100 schrieb Andreas Schwab 
<sch...@linux-m68k.org>:

On Jan 07 2023, Greg Wooledge wrote:
...
I think the original overflow can only happen if the argument of
intrand32 is bigger than INT_MAX.

Question might be if an overflow does any harm - or maybe even is intended...

Positive-to-negative overflow doesn't hurt the algorithm, but since
overflow is undefined behavior, anything can happen.

--
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    c...@case.edu    http://tiswww.cwru.edu/~chet/


Reply via email to