From:             daniel dot oconnor at gmail dot com
Operating system: Debian 5.0.2 
PHP version:      5.3.1
PHP Bug Type:     Unknown/Other Function
Bug description:  Memory leak(s), 64 bit?

Description:
------------
I'm seeing:

[Tue Feb 16 08:05:07 2010]  Script:  'tests/AllTests.php'
/usr/src/php-5.3.1/Zend/zend_opcode.c(63) :  Freeing 0x02090898 (4 bytes),
script=tests/AllTests.php

and a few of it's friends.

The machine is http://wiki.php.net/systems/sg1 - compiled php 5.3.1, 

Reproduce code:
---------------
clockw...@sg1:~/packages-all/Services_ExchangeRates$ php
tests/AllTests.php 



Expected result:
----------------
No memory leaks

Actual result:
--------------
PHPUnit 3.4.10 by Sebastian Bergmann.

.E.EE...........E..EEEIIE

Time: 0 seconds, Memory: 9.75Mb

There were 8 errors:

1) Services_ExchangeRatesTest::testShouldStoreRetrievedData2
Assigning the return value of new by reference is deprecated

/usr/local/lib/php/pear/XML/Unserializer.php:801
/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates/Common.php:72
/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates/Common.php:72
/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates/Rates_ECB.php:83
/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates.php:189
/home/clockwerx/packages-all/Services_ExchangeRates/tests/Services_ExchangeRatesTest.php:70
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:25
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:49

2) Services_ExchangeRatesTest::testShouldValidateCurrencyCode
Non-static method PEAR::raiseError() should not be called statically,
assuming $this from incompatible context

/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates.php:370
/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates.php:272
/home/clockwerx/packages-all/Services_ExchangeRates/tests/Services_ExchangeRatesTest.php:102
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:25
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:49

3) Services_ExchangeRatesTest::testShouldNotConvertInvalidCurrencies
Non-static method PEAR::raiseError() should not be called statically,
assuming $this from incompatible context

/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates.php:370
/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates.php:272
/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates.php:292
/home/clockwerx/packages-all/Services_ExchangeRates/tests/Services_ExchangeRatesTest.php:112
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:25
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:49

4) Services_ExchangeRatesCommonTest::testShouldParseXML
Use of undefined constant XML_UNSERIALIZER_OPTION_ATTRIBUTES_PARSE -
assumed 'XML_UNSERIALIZER_OPTION_ATTRIBUTES_PARSE'

/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates/Common.php:77
/home/clockwerx/packages-all/Services_ExchangeRates/tests/Services_ExchangeRatesCommonTest.php:23
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:25
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:49

5)
Services_ExchangeRates_CurrenciesUNTest::testShouldParseInformationCorrectly
Use of undefined constant XML_UNSERIALIZER_OPTION_ATTRIBUTES_PARSE -
assumed 'XML_UNSERIALIZER_OPTION_ATTRIBUTES_PARSE'

/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates/Common.php:77
/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates/Currencies_UN.php:76
/home/clockwerx/packages-all/Services_ExchangeRates/tests/Services_ExchangeRates_CurrenciesUNTest.php:36
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:25
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:49

6) Services_ExchangeRates_RatesECBTest::testShouldRetrieveInformation
Use of undefined constant XML_UNSERIALIZER_OPTION_ATTRIBUTES_PARSE -
assumed 'XML_UNSERIALIZER_OPTION_ATTRIBUTES_PARSE'

/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates/Common.php:77
/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates/Rates_ECB.php:83
/home/clockwerx/packages-all/Services_ExchangeRates/tests/Services_ExchangeRates_RatesECBTest.php:34
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:25
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:49

7) Services_ExchangeRates_RatesNBPTest::testShouldRetrieveInformation
Use of undefined constant XML_UNSERIALIZER_OPTION_ATTRIBUTES_PARSE -
assumed 'XML_UNSERIALIZER_OPTION_ATTRIBUTES_PARSE'

/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates/Common.php:77
/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates/Rates_NBP.php:106
/home/clockwerx/packages-all/Services_ExchangeRates/tests/Services_ExchangeRates_RatesNBPTest.php:60
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:25
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:49

8) Services_ExchangeRates_RatesNBITest::testShouldRetrieveInformation
Use of undefined constant XML_UNSERIALIZER_OPTION_ATTRIBUTES_PARSE -
assumed 'XML_UNSERIALIZER_OPTION_ATTRIBUTES_PARSE'

/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates/Common.php:77
/home/clockwerx/packages-all/Services_ExchangeRates/Services/ExchangeRates/Rates_NBI.php:78
/home/clockwerx/packages-all/Services_ExchangeRates/tests/Services_ExchangeRates_RatesNBITest.php:43
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:25
/home/clockwerx/packages-all/Services_ExchangeRates/tests/AllTests.php:49

FAILURES!
Tests: 25, Assertions: 20, Errors: 8, Incomplete: 2.
[Tue Feb 16 08:05:07 2010]  Script:  'tests/AllTests.php'
/usr/src/php-5.3.1/Zend/zend_vm_execute.h(17741) :  Freeing 0x02947B38 (41
bytes), script=tests/AllTests.php
Last leak repeated 4 times
[Tue Feb 16 08:05:07 2010]  Script:  'tests/AllTests.php'
Zend/zend_language_scanner.l(1795) :  Freeing 0x0283FAC8 (40 bytes),
script=tests/AllTests.php
Last leak repeated 48 times
[Tue Feb 16 08:05:07 2010]  Script:  'tests/AllTests.php'
/usr/src/php-5.3.1/Zend/zend_operators.c(1856) :  Freeing 0x02841010 (7
bytes), script=tests/AllTests.php
Last leak repeated 24 times
[Tue Feb 16 08:05:07 2010]  Script:  'tests/AllTests.php'
/usr/src/php-5.3.1/Zend/zend_opcode.c(377) :  Freeing 0x0284E630 (9240
bytes), script=tests/AllTests.php
[Tue Feb 16 08:05:07 2010]  Script:  'tests/AllTests.php'
Zend/zend_language_scanner.l(1673) :  Freeing 0x027CFC98 (5 bytes),
script=tests/AllTests.php
[Tue Feb 16 08:05:07 2010]  Script:  'tests/AllTests.php'
/usr/src/php-5.3.1/main/spprintf.c(775) :  Freeing 0x027EA8B8 (79 bytes),
script=tests/AllTests.php
[Tue Feb 16 08:05:07 2010]  Script:  'tests/AllTests.php'
Zend/zend_language_scanner.l(313) :  Freeing 0x0208E418 (232 bytes),
script=tests/AllTests.php
[Tue Feb 16 08:05:07 2010]  Script:  'tests/AllTests.php'
/usr/src/php-5.3.1/Zend/zend_opcode.c(63) :  Freeing 0x02090898 (4 bytes),
script=tests/AllTests.php
=== Total 84 memory leaks detected ===


-- 
Edit bug report at http://bugs.php.net/?id=51057&edit=1
-- 
Try a snapshot (PHP 5.2):            
http://bugs.php.net/fix.php?id=51057&r=trysnapshot52
Try a snapshot (PHP 5.3):            
http://bugs.php.net/fix.php?id=51057&r=trysnapshot53
Try a snapshot (PHP 6.0):            
http://bugs.php.net/fix.php?id=51057&r=trysnapshot60
Fixed in SVN:                        
http://bugs.php.net/fix.php?id=51057&r=fixed
Fixed in SVN and need be documented: 
http://bugs.php.net/fix.php?id=51057&r=needdocs
Fixed in release:                    
http://bugs.php.net/fix.php?id=51057&r=alreadyfixed
Need backtrace:                      
http://bugs.php.net/fix.php?id=51057&r=needtrace
Need Reproduce Script:               
http://bugs.php.net/fix.php?id=51057&r=needscript
Try newer version:                   
http://bugs.php.net/fix.php?id=51057&r=oldversion
Not developer issue:                 
http://bugs.php.net/fix.php?id=51057&r=support
Expected behavior:                   
http://bugs.php.net/fix.php?id=51057&r=notwrong
Not enough info:                     
http://bugs.php.net/fix.php?id=51057&r=notenoughinfo
Submitted twice:                     
http://bugs.php.net/fix.php?id=51057&r=submittedtwice
register_globals:                    
http://bugs.php.net/fix.php?id=51057&r=globals
PHP 4 support discontinued:          http://bugs.php.net/fix.php?id=51057&r=php4
Daylight Savings:                    http://bugs.php.net/fix.php?id=51057&r=dst
IIS Stability:                       
http://bugs.php.net/fix.php?id=51057&r=isapi
Install GNU Sed:                     
http://bugs.php.net/fix.php?id=51057&r=gnused
Floating point limitations:          
http://bugs.php.net/fix.php?id=51057&r=float
No Zend Extensions:                  
http://bugs.php.net/fix.php?id=51057&r=nozend
MySQL Configuration Error:           
http://bugs.php.net/fix.php?id=51057&r=mysqlcfg

Reply via email to