php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #34580 Segmentation fault
Submitted: 2005-09-21 15:52 UTC Modified: 2005-09-29 01:00 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: acraft at nb dot sympatico dot ca Assigned:
Status: No Feedback Package: Class/Object related
PHP Version: 5.1.0RC1 OS: Fedora Core release 3
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: acraft at nb dot sympatico dot ca
New email:
PHP Version: OS:

 

 [2005-09-21 15:52 UTC] acraft at nb dot sympatico dot ca
Description:
------------
When using a php function to create the variable for a class method a segmentation fault occurs.

Reproduce code:
---------------
$ts = '112005';

$cal->initCalendarDMY(1, substr($ts, 0, 2), substr($ts, 2) );

Expected result:
----------------
No Segmemtation Fault

Actual result:
--------------
(gdb) bt
#0  0xb7bb11cb in _zval_copy_ctor_func (zvalue=0xbf89ee34)
    at /root/src/php-5.1.0RC1/Zend/zend_variables.c:141
#1  0xb7be66e5 in ZEND_CAST_SPEC_VAR_HANDLER (execute_data=0xbf89ee60) at zend_variables.h:45
#2  0xb7bd1911 in execute (op_array=0x9d5b614) at zend_vm_execute.h:87
#3  0xb7bd1b03 in zend_do_fcall_common_helper_SPEC (execute_data=0xbf89f6d0) at zend_vm_execute.h:219
#4  0xb7bd1911 in execute (op_array=0x9c26344) at zend_vm_execute.h:87
#5  0xb7bd1b03 in zend_do_fcall_common_helper_SPEC (execute_data=0xbf8a06e0) at zend_vm_execute.h:219
#6  0xb7bd1911 in execute (op_array=0x9cf542c) at zend_vm_execute.h:87
#7  0xb7bb280e in zend_execute_scripts (type=8, retval=0x0, file_count=3)
    at /root/src/php-5.1.0RC1/Zend/zend.c:1078
#8  0xb7b7fe68 in php_execute_script (primary_file=0xbf8a2a40)
    at /root/src/php-5.1.0RC1/main/main.c:1672
#9  0xb7c30275 in php_handler (r=0x9aa2600)
    at /root/src/php-5.1.0RC1/sapi/apache2handler/sapi_apache2.c:562
#10 0x080af63a in ap_run_handler (r=0x9aa2600) at config.c:152
#11 0x080afa05 in ap_invoke_handler (r=0x9aa2600) at config.c:364
#12 0x0809f151 in ap_process_request (r=0x9aa2600) at http_request.c:249
#13 0x0809ae19 in ap_process_http_connection (c=0x9a9a360) at http_core.c:251
#14 0x080b8b02 in ap_run_process_connection (c=0x9a9a360) at connection.c:43
#15 0x080ade15 in child_main (child_num_arg=Variable "child_num_arg" is not available.
) at prefork.c:610
#16 0x080ae009 in make_child (s=0x991afd0, slot=0) at prefork.c:650
#17 0x080ae0d0 in startup_children (number_to_start=5) at prefork.c:722
#18 0x080ae7a3 in ap_mpm_run (_pconf=0x99160a8, plog=0x994e188, s=0x991afd0) at prefork.c:941
#19 0x080b38a3 in main (argc=2, argv=0xbf8a2f14) at main.c:618

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-09-21 15:54 UTC] acraft at nb dot sympatico dot ca
The following does not cause a seg fault.

$ts = '112005';

$t1 = substr($ts, 0, 2);
$t2 =  substr($ts, 2);

$cal->initCalendarDMY(1, $t1, $t2 );
 [2005-09-21 16:06 UTC] tony2001@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves. 

A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external 
resources such as databases, etc.

If possible, make the script source available online and provide
an URL to it here. Try to avoid embedding huge scripts into the report.


 [2005-09-21 18:39 UTC] acraft at nb dot sympatico dot ca
I am sorry this was my fault, I thought I had checked everything but missed something. I apologize for wasting your time.
 [2005-09-21 21:50 UTC] tony2001@php.net
Hmm.. I'm still curious what was the reason for the segfault.
Could you provide a short but complete reproduce case?
Or at least tell me how exactly did you fix it?
 [2005-09-29 01:00 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 17:01:58 2024 UTC