php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #21180 apd (probably apd_execute ();) initiates segfault in php-cli
Submitted: 2002-12-25 06:32 UTC Modified: 2003-07-29 07:23 UTC
From: tony2001 at ua dot fm Assigned: gschlossnagle (profile)
Status: No Feedback Package: PEAR related
PHP Version: 4.3.0RC4 OS: RH 7.3
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: tony2001 at ua dot fm
New email:
PHP Version: OS:

 

 [2002-12-25 06:32 UTC] tony2001 at ua dot fm
(gdb) run ./pprofp -u /usr/local/lib/php/extensions/apd/pprof.02929
Starting program: /usr/local/bin/php ./pprofp -u /usr/local/lib/php/extensions/apd/pprof.02929
<skipped dump>
Program received signal SIGSEGV, Segmentation fault.
0x080fe6c2 in zend_get_executed_lineno () at /root/CVS/php-4.3.0RC4/Zend/zend_execute_API.c:269
269                     return active_opline->lineno;
(gdb) bt
#0  0x080fe6c2 in zend_get_executed_lineno () at /root/CVS/php-4.3.0RC4/Zend/zend_execute_API.c:269
#1  0x4010ef78 in apd_execute () from /usr/local/lib/php/extensions/apd.so
#2  0x080ff18e in call_user_function_ex (function_table=0x8157588, object_pp=0x0, function_name=0x81ced2c,
    retval_ptr_ptr=0xbffff0e8, param_count=0, params=0x81ca19c, no_separation=1, symbol_table=0x0)
    at /root/CVS/php-4.3.0RC4/Zend/zend_execute_API.c:557
#3  0x080feb94 in call_user_function (function_table=0x8157588, object_pp=0x0, function_name=0x81ced2c,
    retval_ptr=0xbffff120, param_count=0, params=0x81936d8) at /root/CVS/php-4.3.0RC4/Zend/zend_execute_API.c:399
#4  0x0807e875 in user_shutdown_function_call (shutdown_function_entry=0x81ceeb4)
    at /root/CVS/php-4.3.0RC4/ext/standard/basic_functions.c:2013
#5  0x0810b800 in zend_hash_apply (ht=0x819b0b4, apply_func=0x807e834 <user_shutdown_function_call>)
    at /root/CVS/php-4.3.0RC4/Zend/zend_hash.c:688
#6  0x0807eaf1 in php_call_shutdown_functions () at /root/CVS/php-4.3.0RC4/ext/standard/basic_functions.c:2094
#7  0x080e003f in php_request_shutdown (dummy=0x0) at /root/CVS/php-4.3.0RC4/main/main.c:924
#8  0x08121f17 in main (argc=4, argv=0xbffff8e4) at /root/CVS/php-4.3.0RC4/sapi/cli/php_cli.c:803
#9  0x42017499 in __libc_start_main () from /lib/i686/libc.so.6

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-04-02 10:56 UTC] sniper@php.net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.


 [2003-04-03 01:46 UTC] tony2001 at ua dot fm
I've tested it with php-STABLE.
It seems to be working ok, but I'll continue testing.
Thanks to you.
 [2003-05-13 09:43 UTC] dholmes at jccc dot net
I'm running php 4.3.1 (custom build) with apd 0.4p2 on RH 8.0 yet I get roughly the same problem.  The ticket is currently closed, but since 4.3.1 was most likely the STABLE cvs release you spoke of...I figured I'd update the ticket.  

Here is what my dump looked like.  Trying different flags yields similar results... 20 rows of info then segfault.  Granted...it's a biggish system I'm trying to profile. ;-)

Anyway...great stuff!!!

---------------------------

(gdb) FILE /usr/local/bin/php
Reading symbols from /usr/local/bin/php...done.
(gdb) set args ./pprofp  -u /tmp/dump_dir/dholmes/pprof.22134
(gdb) run
Starting program: /vol1/local/bin/php ./pprofp  -u /tmp/dump_dir/dholmes/pprof.22134
[New Thread 16384 (LWP 22338)]

Trace for /vol1/home/dholmes/site_html/www.remote-clean/admin/common.inc
Total Elapsed Time =    2.40
Total System Time  =    0.07
Total User Time    =    1.75


         Real         User        System             secs/    cumm
%Time (excl/cumm)  (excl/cumm)  (excl/cumm) Calls    call    s/call  Memory Usage Name
--------------------------------------------------------------------------------------
 46.3  0.90  0.90   0.81  0.81   0.01  0.01  15292   0.0001    0.0001        12760 strlen
 10.9  0.30  0.30   0.19  0.19   0.00  0.00   920   0.0002    0.0002       198040 mysql_fetch_array
  2.9  0.10  0.10   0.05  0.05   0.00  0.00   390   0.0001    0.0001       -90296 get_class
  2.3  0.11  0.11   0.04  0.04   0.00  0.00   565   0.0001    0.0001        35208 is_object
  2.3  0.05  0.05   0.04  0.04   0.01  0.01     5   0.0080    0.0080       701664 require_once
  2.3  0.03  0.22   0.04  0.05   0.00  0.00   107   0.0004    0.0005      -109120 sm_sectiontag->getvar
  2.3  0.01  0.01   0.04  0.04   0.00  0.00    87   0.0005    0.0005         4352 mysql_escape_string
  2.3  0.10  0.10   0.04  0.04   0.00  0.00   107   0.0004    0.0004          552 mysql_query
  1.7  0.20  0.20   0.03  0.03   0.00  0.00   396   0.0001    0.0001        31368 sizeof
  1.7  0.02  0.32   0.03  0.22   0.00  0.00   935   0.0000    0.0002       145368 db_mysql->fetchinto
  1.1  0.01  0.01   0.02  0.02   0.00  0.00    91   0.0002    0.0002        10328 gettype
  1.1  0.00  0.00   0.02  0.02   0.00  0.00    64   0.0003    0.0003         3656 db_result->db_result
  1.1  0.02  0.02   0.02  0.02   0.00  0.00     2   0.0100    0.0100       278784 define
  1.1  0.00  0.01   0.02  0.02   0.01  0.01    77   0.0003    0.0003          976 resource_version->_startelement
  1.1  0.02  0.12   0.02  0.09   0.01  0.02    17   0.0012    0.0053       448376 include_once
  1.1  0.02  0.02   0.02  0.02   0.00  0.00   262   0.0001    0.0001         2296 is_resource
  1.1  0.07  0.07   0.02  0.02   0.01  0.01   556   0.0000    0.0000        21768 is_array
  0.6  0.01  0.01   0.01  0.01   0.00  0.00   107   0.0001    0.0001       -21000 db_mysql->modifyquery
  0.6  0.01  0.31   0.01  0.21   0.01  0.01   871   0.0000    0.0002         6072 db_mysql->fetchrow
  0.6  0.00  0.23   0.01  0.10   0.00  0.01   107   0.0001    0.0009         -848 db_mysql->simplequery

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 16384 (LWP 22338)]
0x0811a65e in zend_get_executed_lineno () at /vol1/home/dholmes/build/php-4.3.1/Zend/zend_execute_API.c:269
269                     return active_opline->lineno;
(gdb) bt
#0  0x0811a65e in zend_get_executed_lineno () at /vol1/home/dholmes/build/php-4.3.1/Zend/zend_execute_API.c:269
#1  0x40017dec in apd_execute () from /usr/local/lib/php/extensions/no-debug-non-zts-20020429/apd.so
#2  0x0811af0f in call_user_function_ex (function_table=0x81788c0, object_pp=0x0, function_name=0x81fe5dc, retval_ptr_ptr=0xbfffd638, 
    param_count=0, params=0x81be39c, no_separation=1, symbol_table=0x0) at /vol1/home/dholmes/build/php-4.3.1/Zend/zend_execute_API.c:557
#3  0x0811aa1f in call_user_function (function_table=0x8178d08, object_pp=0x0, function_name=0x81fe5dc, retval_ptr=0xbfffd670, param_count=0, 
    params=0x81c3090) at /vol1/home/dholmes/build/php-4.3.1/Zend/zend_execute_API.c:399
#4  0x080a09f8 in user_shutdown_function_call (shutdown_function_entry=0x81fe764)
    at /vol1/home/dholmes/build/php-4.3.1/ext/standard/basic_functions.c:2013
#5  0x08125e39 in zend_hash_apply (ht=0x81fecbc, apply_func=0x80a09bc <user_shutdown_function_call>)
    at /vol1/home/dholmes/build/php-4.3.1/Zend/zend_hash.c:688
#6  0x080a0c8d in php_call_shutdown_functions () at /vol1/home/dholmes/build/php-4.3.1/ext/standard/basic_functions.c:2094
#7  0x080fc3bf in php_request_shutdown (dummy=0x0) at /vol1/home/dholmes/build/php-4.3.1/main/main.c:924
#8  0x08132df5 in main (argc=4, argv=0xbfffde54) at /vol1/home/dholmes/build/php-4.3.1/sapi/cli/php_cli.c:803
#9  0x420158f7 in __libc_start_main () from /lib/i686/libc.so.6
 [2003-07-24 02:32 UTC] meebey@php.net
Please try using this CVS snapshot:

  http://snaps.php.net/php4-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-STABLE-latest.zip

and report if you still got the problem...

 [2003-07-29 07:23 UTC] sniper@php.net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Mar 28 13:01:28 2024 UTC