|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2011-07-20 10:06 UTC] paulgao at yeah dot net
Description:
------------
if apc ext is compiled with php, core dumped.
if drop APC, coredump is gone.
Reproduce code:
---------------
/usr/local/php/sbin/php-fpm --fpm-config /home/codebase/server-config/php-fpm-www-test.ini
Expected result:
----------------
(gdb) bt
#0 0x00007f2587c469a5 in raise () from /lib64/libc.so.6
#1 0x00007f2587c48185 in abort () from /lib64/libc.so.6
#2 0x00007f2587c83d5b in __libc_message () from /lib64/libc.so.6
#3 0x00007f2587c89676 in malloc_printerr () from /lib64/libc.so.6
#4 0x00000000006bc0bd in destroy_zend_class (pce=<value optimized out>) at /root/php-5.4.0alpha2/Zend/zend_opcode.c:331
#5 0x00000000006d09d3 in zend_hash_clean (ht=0x2ea0c90) at /root/php-5.4.0alpha2/Zend/zend_hash.c:596
#6 0x00000000004a17fc in apc_interned_strings_shutdown () at /root/php-5.4.0alpha2/ext/apc/apc_string.c:226
#7 0x000000000049a1f9 in apc_module_shutdown () at /root/php-5.4.0alpha2/ext/apc/apc_main.c:895
#8 0x0000000000491097 in zm_shutdown_apc (type=<value optimized out>, module_number=6) at /root/php-5.4.0alpha2/ext/apc/php_apc.c:373
#9 0x00000000006c9b45 in module_destructor (module=0x2ebc180) at /root/php-5.4.0alpha2/Zend/zend_API.c:2248
#10 0x00000000006d03eb in zend_hash_apply_deleter (ht=0xee7e40, p=0x2ebc120) at /root/php-5.4.0alpha2/Zend/zend_hash.c:650
#11 0x00000000006d0688 in zend_hash_graceful_reverse_destroy (ht=0xee7e40) at /root/php-5.4.0alpha2/Zend/zend_hash.c:687
#12 0x00000000006c4898 in zend_shutdown () at /root/php-5.4.0alpha2/Zend/zend.c:806
#13 0x000000000066b92a in php_module_shutdown () at /root/php-5.4.0alpha2/main/main.c:2264
#14 0x0000000000770939 in fpm_php_cleanup (which=<value optimized out>, arg=<value optimized out>) at /root/php-5.4.0alpha2/sapi/fpm/fpm/fpm_php.c:199
#15 0x00000000007691be in fpm_cleanups_run (type=2) at /root/php-5.4.0alpha2/sapi/fpm/fpm/fpm_cleanup.c:45
#16 0x0000000000775bca in fpm_unix_init_main () at /root/php-5.4.0alpha2/sapi/fpm/fpm/fpm_unix.c:252
#17 0x0000000000768695 in fpm_init (argc=<value optimized out>, argv=<value optimized out>, config=<value optimized out>, prefix=<value optimized out>, pid=<value optimized out>, test_conf=0)
at /root/php-5.4.0alpha2/sapi/fpm/fpm/fpm.c:55
#18 0x000000000076f24a in main (argc=3, argv=0x7fff72a97458) at /root/php-5.4.0alpha2/sapi/fpm/fpm/fpm_main.c:1731
Actual result:
--------------
startup OK.
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 27 08:00:01 2025 UTC |
Don't have a 5.4 build right now, but can you try Index: apc_compile.c =================================================================== --- apc_compile.c (revision 313412) +++ apc_compile.c (working copy) @@ -1700,6 +1700,7 @@ /* Deep-copy the class properties, because they will be modified */ #ifdef ZEND_ENGINE_2_4 + dst->name = apc_string_pmemcpy(src->name, src->name_length+1, pool TSRMLS_CC); dst->default_properties_count = src->default_properties_count; if (src->default_properties_count) { dst->default_properties_table = (zval**) apc_php_malloc((sizeof(zval*) * src->default_properties_count) TSRMLS_CC);same coredumped. #0 0x0000003bdcc329a5 in raise () from /lib64/libc.so.6 #1 0x0000003bdcc34185 in abort () from /lib64/libc.so.6 #2 0x0000003bdcc6fd5b in __libc_message () from /lib64/libc.so.6 #3 0x0000003bdcc75676 in malloc_printerr () from /lib64/libc.so.6 #4 0x00000000006bb30d in destroy_zend_class (pce=<value optimized out>) at /root/php-5.4.0alpha2/Zend/zend_opcode.c:331 #5 0x00000000006cfc23 in zend_hash_clean (ht=0x2383c90) at /root/php-5.4.0alpha2/Zend/zend_hash.c:596 #6 0x00000000004a18ac in apc_interned_strings_shutdown () at /root/php-5.4.0alpha2/ext/apc/apc_string.c:226 #7 0x000000000049a2a9 in apc_module_shutdown () at /root/php-5.4.0alpha2/ext/apc/apc_main.c:895 #8 0x0000000000491127 in zm_shutdown_apc (type=<value optimized out>, module_number=6) at /root/php-5.4.0alpha2/ext/apc/php_apc.c:373 #9 0x00000000006c8d95 in module_destructor (module=0x23a7c80) at /root/php-5.4.0alpha2/Zend/zend_API.c:2248 #10 0x00000000006cf63b in zend_hash_apply_deleter (ht=0xee6e40, p=0x23a7c20) at /root/php-5.4.0alpha2/Zend/zend_hash.c:650 #11 0x00000000006cf8d8 in zend_hash_graceful_reverse_destroy (ht=0xee6e40) at /root/php-5.4.0alpha2/Zend/zend_hash.c:687 #12 0x00000000006c3ae8 in zend_shutdown () at /root/php-5.4.0alpha2/Zend/zend.c:806 #13 0x000000000066ac4a in php_module_shutdown () at /root/php-5.4.0alpha2/main/main.c:2258 #14 0x000000000076f999 in fpm_php_cleanup (which=<value optimized out>, arg=<value optimized out>) at /root/php-5.4.0alpha2/sapi/fpm/fpm/fpm_php.c:199 #15 0x000000000076823e in fpm_cleanups_run (type=2) at /root/php-5.4.0alpha2/sapi/fpm/fpm/fpm_cleanup.c:45 #16 0x0000000000774c2a in fpm_unix_init_main () at /root/php-5.4.0alpha2/sapi/fpm/fpm/fpm_unix.c:252 #17 0x0000000000767715 in fpm_init (argc=<value optimized out>, argv=<value optimized out>, config=<value optimized out>, prefix=<value optimized out>, pid=<value optimized out>, test_conf=0) at /root/php-5.4.0alpha2/sapi/fpm/fpm/fpm.c:55 #18 0x000000000076e2ca in main (argc=3, argv=0x7fff5fd6c9e8) at /root/php-5.4.0alpha2/sapi/fpm/fpm/fpm_main.c:1726