Bug #78015 [NEW]: Fatal error when Opcache enabled on PHP 7.3.5 under Linux
| From: | andrejs dot verza at gmail dot com | Date: | Wed, 15 May 2019 11:10:05 +0000 |
| Subject: | Bug #78015 [NEW]: Fatal error when Opcache enabled on PHP 7.3.5 under Linux | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-220858@lists.php.net to get a copy of this message | ||
From: andrejs dot verza at gmail dot com
Operating system: Ubuntu 18.04
PHP version: 7.3.5
Package: opcache
Bug Type: Bug
Bug description:Fatal error when Opcache enabled on PHP 7.3.5 under Linux
Description:
------------
PHP 7.3.5 throws a "Fatal error: Uncaught Error: Unsupported operand
types ..." when opcache is enabled in php.ini on Ubuntu Linux 16.04,
18.04, 19.04.
Notes:
- The error is only thrown on a first http request after server started
or restarted (the following requests work as expected).
- The error is thrown on Apache web server as well as on a PHP built-in
web server.
- The error is not present on Windows.
Workaround:
Set opcache.optimization_level=0x7FFFBFDF in php.ini (instead of the
default value 0x7FFFBFFF).
Test script:
---------------
index.php:
<?php require_once 'simple.php'; ?>
simple.php:
<?php
$x = 1;
function f() {
global $x;
$a = ['b' => [$x], 'c' => [$x]];
$d = $a['b'] + $a['c'];
}
Expected result:
----------------
Empty output, no PHP errors.
Actual result:
--------------
Fatal error: Uncaught Error: Unsupported operand types in
/var/www/html/index.php:1 Stack trace: #0 {main} thrown in
/var/www/html/index.php on line 1
--
Edit bug report at https://bugs.php.net/bug.php?id=78015&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=78015&r=trysnapshot54
Try a snapshot (PHP 5.5): https://bugs.php.net/fix.php?id=78015&r=trysnapshot55
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=78015&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=78015&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=78015&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=78015&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=78015&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=78015&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=78015&r=support
Expected behavior: https://bugs.php.net/fix.php?id=78015&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=78015&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=78015&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=78015&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=78015&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=78015&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=78015&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=78015&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=78015&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=78015&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=78015&r=mysqlcfg