[Eisfair] Nach Update php8 4.3.0 Fehlermeldungen

Juergen Edner juergen at eisfair.org
Sa Apr 6 07:36:41 CEST 2024


Hallo Dirk,

> PHP Warning:  Invalid "upload_max_filesize" setting. Invalid quantity 
> "2G": value is out of range, using overflow result for backwards 
> compatibility in Unknown on line 0
> PHP Warning:  Invalid "post_max_size" setting. Invalid quantity "3G": 
> value is out of range, using overflow result for backwards compatibility 
> in Unknown on line 0

der Standardwert dieses Parameters ist meines Wissens auf 2M 
eingestellt, ich persönlich verwendet einen Wert von 16M. Ein Wert von 
2G scheint mir doch sehr überdimensioniert zu sein.

Ich habe schnell einmal im Internet danach gesucht und bin im PHP8 
Source Code fündig geworden 
(https://github.com/php/php-src/blob/0a0e8064e044b133da423952d8e78d50c4841a2e/main/php_globals.h#L89):

   zend_long upload_max_filesize

Darüber hinaus findet man folgende Information 
(https://www.phpinternalsbook.com/php7/zvals/basic_structure.html):

   There are some things that one should be aware of about the zend_long
   type: Firstly, this is a signed integer type, i.e. it can store both
   positive and negative integers, but is commonly not well suited for
   doing bitwise operations. Secondly, zend_long is not the same as long,
   because it abstracts away platform differences. zend_long is always 4
   bytes large on 32-bit platorms and 8 bytes large on 64-bit platforms,
   even if the long type may have a different size.

Der maximal möglich Wert ist demnach 
(https://stackoverflow.com/questions/32525590/what-is-the-maximum-allowed-value-of-max-execution-time-in-php-ini)

   2.147.483.647

Schnell einmal geschaut wie viel Byte 2G entsprechen:

   2G = 2 * 1024 * 1024 * 1024 = 2.147.483.648

Spot the difference!

Gruß Jürgen

-- 
Mail: juergen at eisfair.org



Mehr Informationen über die Mailingliste Eisfair