ID: 42002
Updated by: [EMAIL PROTECTED]
Reported By: klavs at austin dot ibm dot com
-Status: Open
+Status: Bogus
Bug Type: Dynamic loading
Operating System: aix 5.3 TL06
PHP Version: 4.4.7
New Comment:
Do not file bugs when you have Zend extensions (zend_extension=)
loaded. Examples are Zend Optimizer, Zend Debugger, Turck MM Cache,
APC, Xdebug and ionCube loader. These extensions often modify engine
behavior which is not related to PHP itself.
We don't support 3rd party extensions either.
Previous Comments:
------------------------------------------------------------------------
[2007-07-15 19:28:08] klavs at austin dot ibm dot com
Description:
------------
This example is from loading xcache-1.2.1
Others like ZendOptimizer, eAccelerator, APC fail the same way. The
only extension that does not seem to fail is the
ZendExtensionManager.so
It fails the same way with 3.2.8, any clues as to what is wrong here.
Apache is compiled with the following options
CFLAGS="-O2 -bexpall"
./configure \
--prefix=/usr/local/apache2 \
--enable-so \
--with-mpm=prefork
PHP
CFLAGS="-O2 -bexpall" \
./configure \
--prefix=/usr/local/php \
--with-apxs2=/usr/local/apache2/bin/apxs \
--with-mysql \
--enable-memory-limit \
--with-zlib \
--enable-tokenizer \
--disable-versioning
The library seems to be intact
# ldd /usr/local/Zend/lib/Optimizer-2_6_2/php-4.4.x/ZendOptimizer. so
/usr/local/Zend/lib/Optimizer-2_6_2/php-4.4.x/ZendOptimizer. so needs:
/usr/lib/libc.a(shr.o)
/usr/lib/librtl.a(shr.o)
/unix
/usr/lib/libcrypt.a(shr.o)
Top part of phpinfo() reads like this when the Zend Optimizer is
removed from php.ini
phpinfo()
PHP Version => 4.4.6
System => AIX winter 3 5 000AC45CD600
Build Date => Jul 10 2007 17:29:26
Configure Command => './configure' '--prefix=/usr/local/php'
'--with-apxs2=/usr/local/apache2/bin/apxs' '--with-mysql' '--e
nable-memory-limit' '--with-zlib' '--enable-tokenizer'
'--disable-versioning'
Server API => Command Line Interface
Virtual Directory Support => disabled
Configuration File (php.ini) Path => /usr/local/Zend/etc/php.ini
PHP API => 20020918
PHP Extension => 20020429
Zend Extension => 20050606
Debug Build => no
Zend Memory Manager => enabled
Thread Safety => disabled
Registered PHP Streams => php, http, ftp, compress.zlib
This program makes use of the Zend Scripting Language Engine:
Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies
Reproduce code:
---------------
# dbx ../php/bin/php
Type 'help' for help.
[using memory image in core]
reading symbolic information ...
Segmentation fault in xcache_zend_startup at line 2806 in file
"/usr/local/xcache-1.2.1/xcache.c" ($t1)
2806 origin_compile_file = zend_compile_file;
(dbx) list 2800,2820
2800 /* }}} */
2801 ZEND_DLEXPORT int xcache_zend_startup(zend_extension
*extension) /* {{{ */
2802 {
2803 xc_zend_extension_gotup = 1;
2804
2805 if (!origin_compile_file) {
2806 origin_compile_file = zend_compile_file;
2807 zend_compile_file =
xc_check_initial_compile_file;
2808 }
2809
2810 if (zend_llist_count(&zend_extensions) > 1) {
2811 zend_llist_position lpos;
2812 zend_extension *ext;
2813
2814 xc_llist_zend_extension =
xc_llist_get_element_by_zend_extension(&zend_extensions, XCACHE_NAME);
2815 xc_llist_unlink(&zend_extensions,
xc_llist_zend_extension);
2816
2817 ext = (zend_extension *)
zend_llist_get_last_ex(&zend_extensions, &lpos);
2818 assert(ext && ext != xc_llist_zend_extension);
2819 xc_last_ext_startup = ext->startup;
2820 ext->startup = xc_zend_startup_last;
(dbx) where
xcache_zend_startup(extension = 0x2006e590), line 2806 in "xcache.c"
[EMAIL PROTECTED]() at 0x10039bb8
zend_llist_apply_with_del() at 0x10023770
zend_startup_extensions() at 0x100396b4
php_module_startup() at 0x100043c8
php_cli.main() at 0x10000500
(dbx) quit
Expected result:
----------------
Loaded extension
Actual result:
--------------
Segmentation Fault
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=42002&edit=1