Re: [PATCH] prevent integer overflow on 32 bit

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Aug 21, 2015 at 10:23:57AM +0100, Frediano Ziglio wrote:
> On 32 bit machine timespec->tv_sec (time_t) is 32 bit.

"On 32 bit machines, timespec->..."

> Also 1000 * 1000 * 1000 is 32 bit.
> The multiplication 32 x 32 lead to a 32 bit however this can overflow.

"The multiplication of 2 32 bit integers gives a 32 bit integer, however
this can overflow"

> Convert the first factor to 64 bit before multiply solve the issue.

"Converting the first factor to 64 bit before the multiplication solves
the issue" ?

ACK.

Christophe

Attachment: pgprmvv8o__a5.pgp
Description: PGP signature

_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/spice-devel

[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]