php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #57286 Segmentation fault when running encoded file
Submitted: 2006-10-08 04:37 UTC Modified: 2006-12-17 06:36 UTC
From: drew at drew dot co dot il Assigned:
Status: Not a bug Package: bcompiler (PECL)
PHP Version: 4.4.4 OS: RedHat 9.0
Private report: No CVE-ID: None
 [2006-10-08 04:37 UTC] drew at drew dot co dot il
Description:
------------
When running a compiled php file, a segmentation fault occurs.
Files compile okay but fail to run.
The segfault only happens when the Zend Optimizer is loaded.  When I comment out the extension, bcompiler runs as expected.
I am not sure if this is expected but I am posting this anyway since there was not mention in the manual pages or comments.
If this is an error in zend optimizer itself rather than bcompiler I apoligize for posting here.

Reproduce code:
---------------
<?php
include("out.phb");
?>

uncompiled version of out.phb
<?php
echo "BCOMPILER WORKED";
?>


Expected result:
----------------
BCOMPILER WORKED

Actual result:
--------------
Segmentation fault.

(gdb) bt
#0  0x408c6072 in zend_optimizer_set_oe_ex () from /usr/local/Zend/lib/Optimizer-2.5.10/php-4.4.x/ZendOptimizer.so
#1  0x083c4e28 in ?? ()
#2  0x408c9a96 in zend_optimizer_set_oe_ex () from /usr/local/Zend/lib/Optimizer-2.5.10/php-4.4.x/ZendOptimizer.so
#3  0x408ce795 in zend_oe () from /usr/local/Zend/lib/Optimizer-2.5.10/php-4.4.x/ZendOptimizer.so
#4  0x08161237 in php_execute_script (primary_file=0xbfffda40) at /home/cpapachebuild/buildapache/php-4.4.4/main/main.c:1752
#5  0x081957c0 in main (argc=2, argv=0xbfffdad4) at /home/cpapachebuild/buildapache/php-4.4.4/sapi/cgi/cgi_main.c:1601
#6  0x4071162d in __libc_start_main () from /lib/libc.so.6


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-12-17 06:36 UTC] val@php.net
Thank you for taking the time to write to us, but this is not
a bug.

Currently, bcompiler doesn't work with Zend Optimizer. In my todo for bcompiler 0.9 there're some improvements to bcompiler that might resolve conflicts with Zend Optimizer.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 13:01:30 2024 UTC