Bug #65559 [Opn]: Opcache: cache not cleared if changes occur while running

From: Date: Wed, 23 Oct 2013 14:09:38 +0000
Subject: Bug #65559 [Opn]: Opcache: cache not cleared if changes occur while running
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-182407@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=65559&edit=1 ID: 65559 User updated by: zoeslam at gmail dot com Reported by: zoeslam at gmail dot com Summary: Opcache: cache not cleared if changes occur while running Status: Open Type: Bug Package: opcache Operating System: Ubuntu PHP Version: 5.5.3 Block user comment: N Private report: N New Comment: Of course, if you try the test in CLI, make sure to enable the opcache even in the cli: php -d opcache.enable=1 -d opcache.enable_cli=1 test.php Previous Comments: ------------------------------------------------------------------------ [2013-08-26 12:41:21] zoeslam at gmail dot com Description: ------------ The new Zend OPcache doesn't clear the cache if a file is changed on the fly. Instead the test script works well with opcache turned off (opcache.enable=0). Test script: --------------- <?php $file = __DIR__.'/file.txt'; file_put_contents($file, '<?php return 1;'); $var = include $file; file_put_contents($file, '<?php return 2;'); $var = include $file; var_dump($var); Expected result: ---------------- int(2) Actual result: -------------- int(1) ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=65559&edit=1

« previous php.bugs (#182407) next »