MantisBT

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000141Xdebug(No Category)public2005-08-02 06:042005-12-31 11:35
Reporterdavid 
Assigned To 
PrioritynormalSeveritymajorReproducibilityalways
StatusclosedResolutionopen 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0000141: remote context_get causes segfault
DescriptionUsing context_get from the remote debugging client causes a SEGV on the client script in zend_hash_find.
Additional InformationSource file:
<?php
xdebug_break();
?>

Remote session log:
Waiting for debug server to connect.
Connect
<init fileuri="file:///var/www/live/objects/tests/xdebug.php" [^] language="PHP" protocol_version="1.0" appid="12083" idekey="session_name"><engine version="2.0.0beta3-dev"><![CDATA[Xdebug]]></engine><author><![CDATA[Derick Rethans]]></author><url><![CDATA[http://xdebug.org [^]]]></url><copyright><![CDATA[Copyright (c) 2002-2005 by Derick Rethans]]></copyright></init>
(cmd) run -i TRANSACTION_ID
<response command="run" transaction_id="TRANSACTION_ID" status="break" reason="ok"></response>
(cmd) context_get -i TRANSACTION_ID


gdb backtrace on the php process:
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1077475936 (LWP 12083)]
zend_hash_find (ht=0x0, arKey=0x8328b6c "this", nKeyLength=5, pData=0x106cef7d)
    at /home/lod/downloads/php-src/Zend/zend_hash.c:850
850 nIndex = h & ht->nTableMask;
(gdb) bt
#0 zend_hash_find (ht=0x0, arKey=0x8328b6c "this", nKeyLength=5, pData=0x106cef7d)
    at /home/lod/downloads/php-src/Zend/zend_hash.c:850
#1 0x0818827d in zend_fetch_var_address_helper_SPEC_CONST (type=0, execute_data=0xbfffd360,
    tsrm_ls=0x8268018) at zend_vm_execute.h:1385
0000002 0x08188670 in ZEND_FETCH_R_SPEC_CONST_HANDLER (execute_data=0x106cef7d, tsrm_ls=0x106cef7d)
    at zend_vm_execute.h:1448
0000003 0x0818507c in execute (op_array=0x8334774, tsrm_ls=0x8268018) at zend_vm_execute.h:87
0000004 0x403dee13 in xdebug_execute (op_array=0x8334774, tsrm_ls=0x8268018)
    at /home/lod/xdebug-cvs/xdebug.c:1166
0000005 0x08156390 in zend_eval_string (str=0xbfffd45c "", retval_ptr=0xbfffd4e0,
    string_name=0x106cef7d <Address 0x106cef7d out of bounds>, tsrm_ls=0x8268018)
    at /home/lod/downloads/php-src/Zend/zend_execute_API.c:1042
0000006 0x403e6a7b in _xdebug_do_eval (eval_string=0x106cef7d <Address 0x106cef7d out of bounds>,
    ret_zval=0x106cef7d, tsrm_ls=0x8268018) at /home/lod/xdebug-cvs/xdebug_handler_dbgp.c:1008
0000007 0x403e8750 in add_variable_node (node=0x106cef7d, name=0x403f57d8 "this", name_length=275574653,
    var_only=1, non_null=1, no_eval=0, tsrm_ls=0x8268018)
    at /home/lod/xdebug-cvs/xdebug_handler_dbgp.c:1381
0000008 0x403e9a19 in attach_context_vars (node=0x8328d68, options=0x106cef7d, context_id=0,
    depth=275574653, func=0x106cef7d, tsrm_ls=0x8268018)
    at /home/lod/xdebug-cvs/xdebug_handler_dbgp.c:1591
0000009 0x403ea0b1 in xdebug_dbgp_handle_context_get (retval=0xbfffd5cc, context=0x106cef7d,
    args=0x8333df8, tsrm_ls=0x8268018) at /home/lod/xdebug-cvs/xdebug_handler_dbgp.c:1676
0000010 0x403ea696 in xdebug_dbgp_parse_option (context=0x106cef7d,
    line=0x106cef7d <Address 0x106cef7d out of bounds>, flags=0, retval=0x8328d68, tsrm_ls=0x8268018)
    at /home/lod/xdebug-cvs/xdebug_handler_dbgp.c:1870
0000011 0x403ea837 in xdebug_dbgp_cmdloop (context=0x82dc234, tsrm_ls=0x8268018)
    at /home/lod/xdebug-cvs/xdebug_handler_dbgp.c:1909
0000012 0x403eb4df in xdebug_dbgp_breakpoint (context=0x82dc234, stack=0x83326f8,
    file=0x8332d0c "/var/www/live/objects/tests/xdebug.php", lineno=2, type=1)
    at /home/lod/xdebug-cvs/xdebug_handler_dbgp.c:2135
0000013 0x403e200b in zif_xdebug_break (ht=0, return_value=0x833273c, return_value_ptr=0x0, this_ptr=0x0,
    return_value_used=0, tsrm_ls=0x8268018) at /home/lod/xdebug-cvs/xdebug.c:2061
0000014 0x08184f67 in execute_internal (execute_data_ptr=0x106cef7d, return_value_used=275574653,
    tsrm_ls=0x106cef7d) at /home/lod/downloads/php-src/Zend/zend_execute.c:1328
0000015 0x403df7d9 in xdebug_execute_internal (current_execute_data=0xbfffd750,
    return_value_used=275574653, tsrm_ls=0x8268018) at /home/lod/xdebug-cvs/xdebug.c:1223
0000016 0x08185a0b in zend_do_fcall_common_helper_SPEC (execute_data=0xbfffd750, tsrm_ls=0x8268018)
    at zend_vm_execute.h:186
0000017 0x0818507c in execute (op_array=0x8332ddc, tsrm_ls=0x8268018) at zend_vm_execute.h:87
0000018 0x403dee13 in xdebug_execute (op_array=0x8332ddc, tsrm_ls=0x8268018)
    at /home/lod/xdebug-cvs/xdebug.c:1166
0000019 0x0816058c in zend_execute_scripts (type=8, tsrm_ls=0x8268018, retval=0x0, file_count=3)
    at /home/lod/downloads/php-src/Zend/zend.c:1078
0000020 0x081205d4 in php_execute_script (primary_file=0xbffffbe0, tsrm_ls=0x8268018)
    at /home/lod/downloads/php-src/main/main.c:1672
0000021 0x081dc7ea in main (argc=3, argv=0xbffffcb4) at /home/lod/downloads/php-src/sapi/cli/php_cli.c:1039

Running latest CVS xdebug and latest CVS php.
(Tue Aug 2 14:03:52 EST 2005)
TagsNo tags attached.
Operating SystemDebian Linux
PHP Version5.1.0-dev
Attached Files

- Relationships
has duplicate 0000151resolvedderick cannot go past xdebug_break() 

-  Notes
(0000328)
derick (administrator)
2005-12-31 11:35

Fixed in CVS, thanks for the report!

- Issue History
Date Modified Username Field Change
2005-08-02 06:04 david New Issue
2005-12-31 11:34 derick Relationship added has duplicate 0000151
2005-12-31 11:35 derick Status new => closed
2005-12-31 11:35 derick Note Added: 0000328
2016-07-31 13:35 derick Category Debug client (console) => debugclient (debugging tool)
2016-07-31 13:35 derick Category debugclient (debugging tool) => (No Category)


Copyright © 2000 - 2017 MantisBT Team
Powered by Mantis Bugtracker