PHP  
 PHP_HEAD
downloads | QA | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | my php.net 
 

Valgrind Report for ext/interbase/tests/ibase_free_query_001.phpt ('ibase_free_query(): Basic test')

Script

1: <?php
2:
3:
require("interbase.inc");
4:
5:
$x ibase_connect($test_base);
6:
7:
$q =ibase_prepare($x'SELECT 1 FROM test1 WHERE i = ?');
8:
$q =ibase_prepare($x'SELECT 1 FROM test1 WHERE i = ?');
9:
$q ibase_prepare($x'SELECT 1 FROM test1 WHERE i = ?');
10:
11:
var_dump(ibase_free_query($q));
12:
var_dump(ibase_free_query($q));
13:
var_dump(ibase_free_query($x));
14:
15:
?>
16:

Report

==29273== Invalid read of size 4
==29273==    at 0x5F2FA82: ??? (in /usr/lib64/libfbclient.so.2.5.7)
==29273==    by 0x5F21759: isc_database_info (in /usr/lib64/libfbclient.so.2.5.7)
==29273==    by 0x91DDCA: _php_ibase_free_stmt_handle (ibase_query.c:127)
==29273==    by 0x91E01D: _php_ibase_free_query (ibase_query.c:169)
==29273==    by 0x91E145: php_ibase_free_query_rsrc (ibase_query.c:189)
==29273==    by 0x11496B3: zend_resource_dtor (zend_list.c:76)
==29273==    by 0x114A0BB: zend_close_rsrc (zend_list.c:230)
==29273==    by 0x113EDCA: zend_hash_reverse_apply (zend_hash.c:1664)
==29273==    by 0x114A105: zend_close_rsrc_list (zend_list.c:238)
==29273==    by 0x10CF998: shutdown_executor (zend_execute_API.c:262)
==29273==    by 0x1104B24: zend_deactivate (zend.c:1078)
==29273==    by 0xFED6EF: php_request_shutdown (main.c:1765)
==29273==  Address 0x14ef2ed0 is 0 bytes inside a block of size 32 free'd
==29273==    at 0x4C28BD4: free (vg_replace_malloc.c:529)
==29273==    by 0x10989DD: _efree (zend_alloc.c:2499)
==29273==    by 0x91A286: _php_ibase_close_link (interbase.c:643)
==29273==    by 0x11496B3: zend_resource_dtor (zend_list.c:76)
==29273==    by 0x1149793: zend_list_close (zend_list.c:89)
==29273==    by 0x91B942: _php_ibase_connect (interbase.c:946)
==29273==    by 0x91C26D: zif_ibase_connect (interbase.c:1035)
==29273==    by 0x11ECC6A: ZEND_DO_ICALL_SPEC_RETVAL_USED_HANDLER (zend_vm_execute.h:626)
==29273==    by 0x135470A: execute_ex (zend_vm_execute.h:57836)
==29273==    by 0x10D3CCD: zend_call_function (zend_execute_API.c:792)
==29273==    by 0x10D25B4: _call_user_function_ex (zend_execute_API.c:628)
==29273==    by 0xDC995C: user_shutdown_function_call (basic_functions.c:5042)
==29273==  Block was alloc'd at
==29273==    at 0x4C291FA: malloc (vg_replace_malloc.c:298)
==29273==    by 0x109C748: __zend_malloc (zend_alloc.c:2884)
==29273==    by 0x1093792: _emalloc_32 (zend_alloc.c:2407)
==29273==    by 0x91BD90: _php_ibase_connect (interbase.c:991)
==29273==    by 0x91C26D: zif_ibase_connect (interbase.c:1035)
==29273==    by 0x11ECC6A: ZEND_DO_ICALL_SPEC_RETVAL_USED_HANDLER (zend_vm_execute.h:626)
==29273==    by 0x135470A: execute_ex (zend_vm_execute.h:57836)
==29273==    by 0x1354D5D: zend_execute (zend_vm_execute.h:61747)
==29273==    by 0x1106C44: zend_execute_scripts (zend.c:1538)
==29273==    by 0xFEFA6D: php_execute_script (main.c:2467)
==29273==    by 0x135A51C: do_cli (php_cli.c:1011)
==29273==    by 0x135BF0D: main (php_cli.c:1404)
==29273== 

 

Generated at Mon, 15 Jan 2018 23:48:43 +0000 (6 days ago)

Copyright © 2005-2018 The PHP Group
All rights reserved.