Make WordPress Core

Changes between Version 1 and Version 2 of Ticket #63099, comment 1


Ignore:
Timestamp:
03/15/2025 09:18:12 AM (13 months ago)
Author:
kalonya
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #63099, comment 1

    v1 v2  
    1 The code tries to cast a (float) number to (int) which causes an overflow in a 32-bit system.
     1Maybe we should set the $max_random_number like this?
     2
     3
     4{{{
     5$max_random_number = PHP_INT_SIZE === 4 ? (float) PHP_INT_MAX * 2 + 1 : PHP_INT_MAX;
     6}}}
     7
     8
     9The code tries to cast a (float) number to (int), which causes an overflow in a 32-bit system.