If the format of memory_limit contains a unit character (M,K,G), CSSmin::normalize_int will try to multiply that string by the appropriate unit amount.
Under PHP 7.1, attempting to do so results in:
Notice: A non well formed numeric value encountered
which Craft considers sufficient to throw an exception and error out.
This doesn't cause an issue in previous versions of PHP:
$ php -v
PHP 5.5.38 (cli) (built: Jul 3 2017 15:16:35)
Copyright (c) 1997-2015 The PHP Group
Zend Engine v2.5.0, Copyright (c) 1998-2015 Zend Technologies
$ php -r 'var_dump("1024M" * 1048576);'
int(1073741824)
$ php -v
PHP 5.6.31 (cli) (built: Aug 17 2017 11:33:10)
Copyright (c) 1997-2016 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies
$ php -r 'var_dump("1024M" * 1048576);'
int(1073741824)
$ php -v
PHP 7.0.22 (cli) (built: Aug 17 2017 11:29:35) ( NTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2017 Zend Technologies
$ php -r 'var_dump("1024M" * 1048576);'
int(1073741824)
$ php -v
PHP 7.1.8 (cli) (built: Aug 17 2017 11:34:56) ( NTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.1.0, Copyright (c) 1998-2017 Zend Technologies
$ php -r 'var_dump("1024M" * 1048576);'
Notice: A non well formed numeric value encountered in Command line code on line 1
int(1073741824)
If the format of
memory_limit
contains a unit character (M
,K
,G
),CSSmin::normalize_int
will try to multiply that string by the appropriate unit amount.Under PHP 7.1, attempting to do so results in:
Notice: A non well formed numeric value encountered
which Craft considers sufficient to throw an exception and error out.
This doesn't cause an issue in previous versions of PHP: