|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #78999 Cycle leak when using function result as temporary
Submitted: 2019-12-19 11:34 UTC Modified: 2019-12-19 11:41 UTC
From: Assigned: dmitry (profile)
Status: Closed Package: Scripting Engine problem
PHP Version: 7.4Git-2019-12-19 (Git) OS:
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
Solve the problem:
43 - 29 = ?
Subscribe to this entry?

 [2019-12-19 11:34 UTC]
We destroy temporaries using zval_ptr_dtor_nogc, so the root is not registered.

Test script:
function get() {
    $t = new stdClass;
    $t->prop = $t;
    return $t;


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2019-12-19 11:41 UTC]
-Assigned To: +Assigned To: dmitry
 [2019-12-19 20:19 UTC]
Automatic comment on behalf of
Log: Fixed bug #78999 (Cycle leak when using function result as temporary)
 [2019-12-19 20:19 UTC]
-Status: Assigned +Status: Closed
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Jul 12 11:01:32 2024 UTC