Fix signed integer overflow in random_r (bug 17343)

Paul Eggert eggert@cs.ucla.edu
Tue Mar 20 17:58:00 GMT 2018


On 03/20/2018 10:54 AM, Joseph Myers wrote:
>         *result = (val >> 1) & 0x7fffffff;

One other thing I just noticed: now that val is uint32_t, the above 
should be simplifed to "*result = val >> 1;". The patch looks good 
otherwise; thanks.



More information about the Libc-alpha mailing list