|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[1999-10-03 06:53 UTC] kara at cvs dot php dot net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Nov 04 23:00:01 2025 UTC |
The following short PHP-program produces a segmentation violation. For debug purpose run from the coomand line. Same happens while running as an apache module. <? $cid=odbc_connect('DataBase','user','pass'); $statement="insert into test (field1,field2,field3) values ('hello','test',?)"; $xx=odbc_prepare($cid,$statement); if ($xx) { $LongData[0]="Testing"; $xy=odbc_execute($xx,$LongData); } odbc_close($cid); echo "All_Done"; ?> Debugger output: Script: '/var/web/ricardo2/htdocs/test.phtml' --------------------------------------- odbc.c(1781) : Block 0x08191D38 status: Beginning: OK (allocated on odbc.c:1594, 32 bytes) End: Overflown (magic=0x2A8FCC00 instead of 0x2A8FCC84) 1 byte(s) overflown --------------------------------------- Program received signal SIGSEGV, Segmentation fault. zval_ptr_dtor (zval_ptr=0x81958d0) at zend_execute_API.c:213 213 (*zval_ptr)->refcount--; (gdb) bt #0 zval_ptr_dtor (zval_ptr=0x81958d0) at zend_execute_API.c:213 #1 0x8077adf in zend_hash_destroy (ht=0x81957e8) at zend_hash.c:735 #2 0x8080c29 in php3_odbc_execute (ht=2, return_value=0xbffff5b0, list=0x816b640, plist=0x816b66c, this_ptr=0x0) at odbc.c:736 #3 0x807e44f in execute (op_array=0x81904f0) at zend_execute.c:1410 #4 0x805f4ec in php_execute_script (primary_file=0xbffff7cc) at main.c:1136 #5 0x80650d9 in main (argc=2, argv=0xbffff7f4) at cgi_main.c:448