Bug #72791 [Asn->Csd]: Memory leak in PDO persistent connection handling

From: Date: Tue, 09 Aug 2016 18:22:00 +0000
Subject: Bug #72791 [Asn->Csd]: Memory leak in PDO persistent connection handling
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-203121@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=72791&edit=1 ID: 72791 Updated by: keyur@php.net Reported by: keyur@php.net Summary: Memory leak in PDO persistent connection handling -Status: Assigned +Status: Closed Type: Bug Package: PDO MySQL Operating System: Linux PHP Version: 7.0.9 Assigned To: keyur Block user comment: N Private report: N New Comment: The fix for this bug has been committed. Snapshots of the sources are packaged every three hours; this change will be in the next snapshot. You can grab the snapshot at http://snaps.php.net/. For Windows: http://windows.php.net/snapshots/ Thank you for the report, and for helping us make PHP better. Previous Comments: ------------------------------------------------------------------------ [2016-08-09 05:36:16] keyur@php.net Description: ------------ When the test ext/pdo_mysql/tests/pdo_mysql_pconnect.phpt is run under Valgrind, it reports the following leak: 12 ==7585== 9,915 (184 direct, 9,731 indirect) bytes in 1 blocks are definitely lost in loss record 56 of 56 13 ==7585== at 0x4C29BFD: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so) 14 ==7585== by 0x6D6948: __zend_malloc (zend_alloc.c:2866) 15 ==7585== by 0x6D69B0: __zend_calloc (zend_alloc.c:2875) 16 ==7585== by 0x582718: zim_PDO_dbh_constructor (pdo_dbh.c:311) 17 ==7585== by 0x7714BA: ZEND_DO_FCALL_SPEC_HANDLER (zend_vm_execute.h:842) 18 ==7585== by 0x7338AA: execute_ex (zend_vm_execute.h:414) 19 ==7585== by 0x77CD66: zend_execute (zend_vm_execute.h:458) 20 ==7585== by 0x6F7413: zend_execute_scripts (zend.c:1427) 21 ==7585== by 0x69BD3F: php_execute_script (main.c:2494) 22 ==7585== by 0x77E8EE: do_cli (php_cli.c:974) 23 ==7585== by 0x42F9EE: main (php_cli.c:1344) 24 ==7585== 25 ==7585== LEAK SUMMARY: 26 ==7585== definitely lost: 184 bytes in 1 blocks 27 ==7585== indirectly lost: 9,731 bytes in 34 blocks 28 ==7585== possibly lost: 0 bytes in 0 blocks 29 ==7585== still reachable: 1,606 bytes in 21 blocks 30 ==7585== suppressed: 0 bytes in 0 blocks Test script: --------------- See test ext/pdo_mysql/tests/pdo_mysql_pconnect.phpt Expected result: ---------------- No leaks ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=72791&edit=1

« previous php.bugs (#203121) next »