Bug #80905 [Opn]: VirtualProtect error when proc_open executed in CLI
| From: | cmb@php.net | Date: | Thu, 25 Mar 2021 15:34:29 +0000 |
| Subject: | Bug #80905 [Opn]: VirtualProtect error when proc_open executed in CLI | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-232993@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=80905&edit=1
ID: 80905
Updated by: cmb@php.net
Reported by: gajowy at agzeta dot pl
Summary: VirtualProtect error when proc_open executed in CLI
Status: Open
Type: Bug
Package: JIT
Operating System: Windows 10 64-bit
PHP Version: 8.0.3
Block user comment: N
Private report: N
New Comment:
At least as workaround, enforce separate OPcache instances by
using opcache.cache_id[1]. In this case
$proc=proc_open('php.exe
-dopcache.cache_id=123',[],$pipes,NULL,NULL,['bypass_shell'=>TRUE]);
[1] <https://www.php.net/manual/en/opcache.configuration.php#ini.opcache.cache-id>
Previous Comments:
------------------------------------------------------------------------
[2021-03-25 09:27:07] gajowy at agzeta dot pl
Description:
------------
When JIT mode is enabled, running child process using proc_open causes crash in CLI mode with
VirtualError message.
Test script:
---------------
1. Set opcache.jit_buffer_size=100M in php.ini
2. Run following script in CLI mode:
$proc=proc_open('php.exe',[],$pipes,NULL,NULL,['bypass_shell'=>TRUE]);
print_r( proc_get_status($proc) );
proc_terminate($proc);
Expected result:
----------------
Array
(
[command] => php.exe
[pid] => 13620
[running] => 1
[signaled] =>
[stopped] =>
[exitcode] => -1
[termsig] => 0
[stopsig] => 0
)
Actual result:
--------------
Thu Mar 25 10:20:55 2021 (1612): Fatal Error VirtualProtect() failed
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=80905&edit=1