php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #65395 Memory leak in TSRM.c
Submitted: 2013-08-05 15:10 UTC Modified: 2013-10-15 11:54 UTC
From: naitik dot dani at gmail dot com Assigned:
Status: No Feedback Package: *General Issues
PHP Version: 5.3.25 OS: Freebsd
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: naitik dot dani at gmail dot com
New email:
PHP Version: OS:

 

 [2013-08-05 15:10 UTC] naitik dot dani at gmail dot com
Description:
------------
I am seeing the following backtrace in the memory plumber output which points 
that there is a memory leak with respect to tsrm_tls_entry in TSRM.c file:

==165== at  0x80395a890: __zend_realloc (php-5.3.25/Zend/zend_alloc.h:112)
==165== at  0x80395c7ef: _zend_hash_quick_add_or_update (php-
5.3.25/Zend/zend_hash.c:337)
==165== at  0x80395cb71: zend_hash_copy (php-5.3.25/Zend/zend_hash.c:788)
==165== at  0x80394c269: compiler_globals_ctor (php-5.3.25/Zend/zend.c:506)
==165== at  0x8038e65ca: allocate_new_resource (php-5.3.25/TSRM/TSRM.c:294)
==165== at  0x8038e6709: ts_resource_ex (php-5.3.25/TSRM/TSRM.c:361)
==165== at  0x8039e29f1: php_handler (php-
5.3.25/sapi/apache2handler/sapi_apache2.c:548)

I am using PHP 5.3.25 version. I looked for the patch release after this one 
that might have a fix for it, but I couldn't find one.
I would appreciate if you can throw some light on this memory leak to help me 
fix it. I cannot upgrade to new PHP version due to some inhouse roadblocks. 
However I can patch it to fix this memory leak.

Thanks in advance.

Actual result:
--------------
==165== at  0x80395a890: __zend_realloc (php-5.3.25/Zend/zend_alloc.h:112)
==165== at  0x80395c7ef: _zend_hash_quick_add_or_update (php-
5.3.25/Zend/zend_hash.c:337)
==165== at  0x80395cb71: zend_hash_copy (php-5.3.25/Zend/zend_hash.c:788)
==165== at  0x80394c269: compiler_globals_ctor (php-5.3.25/Zend/zend.c:506)
==165== at  0x8038e65ca: allocate_new_resource (php-5.3.25/TSRM/TSRM.c:294)
==165== at  0x8038e6709: ts_resource_ex (php-5.3.25/TSRM/TSRM.c:361)
==165== at  0x8039e29f1: php_handler (php-
5.3.25/sapi/apache2handler/sapi_apache2.c:548)


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2013-08-09 22:44 UTC] sixd@php.net
-PHP Version: 5.5.1 +PHP Version: 5.3.25
 [2013-08-09 22:47 UTC] sixd@php.net
-Status: Open +Status: Feedback
 [2013-08-09 22:47 UTC] sixd@php.net
How did you configure PHP and what is the testcase that reproduces the problem?
 [2013-10-15 11:54 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Apr 24 12:01:29 2024 UTC