php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #37529 Command line script leaks memory and segfaults
Submitted: 2006-05-19 20:36 UTC Modified: 2006-05-27 01:00 UTC
From: hiro at dusk dot org Assigned:
Status: No Feedback Package: Reproducible crash
PHP Version: 5.1.4 OS: Ubuntu Linux
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2006-05-19 20:36 UTC] hiro at dusk dot org
Description:
------------
A unit test for our application causes a segfault in a certain block of code.  I recompiled PHP 5.1.4. with debugging symbols and it reports a number of memory leaks.  On all systems I've tried it on it either segfaults or produces a bus error.

Reproduce code:
---------------
This is happening deep inside one of the most complex parts of a pretty big application (95,000 lines of PHP not even counting any HTML templates and over 100 classes) and unfortunately I cannot see any way to produce any sort of test case that does not include the entire application.

Actual result:
--------------
[Fri May 19 13:34:56 2006]  Script:  'planchangestackmull'
/home/adam/dl/php-5.1.4/Zend/zend_vm_execute.h(7531) :  Freeing 0x025E83E8 (24 bytes), script=planchangestackmull
Last leak repeated 5 times
[Fri May 19 13:34:56 2006]  Script:  'planchangestackmull'
/home/adam/dl/php-5.1.4/Zend/zend_variables.c(133) :  Freeing 0x0253F608 (64 bytes), script=planchangestackmull
/home/adam/dl/php-5.1.4/Zend/zend_hash.c(169) : Actual location (location was relayed)
Last leak repeated 5 times
[Fri May 19 13:34:56 2006]  Script:  'planchangestackmull'
/home/adam/dl/php-5.1.4/Zend/zend_variables.h(45) :  Freeing 0x024F4208 (72 bytes), script=planchangestackmull/home/adam/dl/php-5.1.4/Zend/zend_variables.c(132) : Actual location (location was relayed)
Last leak repeated 7 times
[Fri May 19 13:34:56 2006]  Script:  'planchangestackmull'
/home/adam/dl/php-5.1.4/Zend/zend_hash.c(760) :  Freeing 0x024F3EE8 (71 bytes), script=planchangestackmull
/home/adam/dl/php-5.1.4/Zend/zend_hash.c(383) : Actual location (location was relayed)
Last leak repeated 9 times
[Fri May 19 13:34:56 2006]  Script:  'planchangestackmull'
/home/adam/dl/php-5.1.4/ext/pgsql/pgsql.c(1968) :  Freeing 0x024233D8 (7 bytes), script=planchangestackmull
Last leak repeated 7 times
[Fri May 19 13:34:56 2006]  Script:  'planchangestackmull'
/home/adam/dl/php-5.1.4/Zend/zend_API.c(1065) :  Freeing 0x021702C8 (24 bytes), script=planchangestackmull
Last leak repeated 7 times
[Fri May 19 13:34:56 2006]  Script:  'planchangestackmull'
/home/adam/dl/php-5.1.4/Zend/zend_vm_execute.h(182) :  Freeing 0x021844E8 (24 bytes), script=planchangestackmull
Last leak repeated 1 time
=== Total 48 memory leaks detected ===


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-05-19 20:39 UTC] pajoye@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves. 

A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external 
resources such as databases, etc.

If possible, make the script source available online and provide
an URL to it here. Try to avoid embedding huge scripts into the report.


 [2006-05-27 01:00 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue May 07 17:01:33 2024 UTC