[php-src] PR #23846: ext/session: Clear in_save_handler recursion guard on bailout
| From: | iliaal | Date: | Tue, 22 Sep 2026 14:24:17 +0000 |
| Subject: | [php-src] PR #23846: ext/session: Clear in_save_handler recursion guard on bailout | ||
| Groups: | php.git-pulls | ||
| Request: | Send a blank email to git-pulls+get-38718@lists.php.net to get a copy of this message | ||
Pull Request: https://github.com/php/php-src/pull/23846
Author: iliaal
A zend_bailout() out of a userland save handler, a fatal error inside write() for instance, skipped
the PS(in_save_handler) = 0 store in ps_call_handler(), so the flag stayed set for the rest of the
request and the shutdown flush refused to call the handler, reporting "Cannot call session save
handler in a recursive manner". The new test forces a real out-of-memory bailout inside write()
and checks that the following write() and close() still run. bug60634_error_3.phpt and
bug60634_error_4.phpt asserted the old warning and now assert the close handler running.
Fixes #15529