Bug #80045 [NEW]: memleak after two set_exception_handler calls with __call

From: Date: Thu, 03 Sep 2020 07:10:26 +0000
Subject: Bug #80045 [NEW]: memleak after two set_exception_handler calls with __call
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-228850@lists.php.net to get a copy of this message
From: sjon Operating system: archLinux PHP version: 8.0.0beta2 Package: *General Issues Bug Type: Bug Bug description:memleak after two set_exception_handler calls with __call Description: ------------ php8 reports a memleak after two set_exception_handler calls combined with an __call Test script: --------------- class x { public function __construct(){ $h = set_exception_handler([$this, 'dummyExceptionHandler']); $h = set_exception_handler([$this, 'dummyExceptionHandler']); } public function __call($m, $p) {} } new x; Actual result: -------------- php-8.0.0beta2/Zend/zend_object_handlers.c(1120) : Freeing 0x00007fd2ab25d780 (232 bytes), script=/tmp/memleak.php === Total 1 memory leaks detected === -- Edit bug report at https://bugs.php.net/bug.php?id=80045&edit=1 -- Fix committed: https://bugs.php.net/fix.php?id=80045&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=80045&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=80045&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=80045&r=needscript Try newer version: https://bugs.php.net/fix.php?id=80045&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=80045&r=support Expected behavior: https://bugs.php.net/fix.php?id=80045&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=80045&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=80045&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=80045&r=globals PHP version support discontinued: https://bugs.php.net/fix.php?id=80045&r=phptooold Daylight Savings: https://bugs.php.net/fix.php?id=80045&r=dst IIS Stability: https://bugs.php.net/fix.php?id=80045&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=80045&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=80045&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=80045&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=80045&r=mysqlcfg

« previous php.bugs (#228850) next »