[php-src] PR #22576: Fix GH-22570: stack overflow serializing a deeply nested Dom\XMLDocument
| From: | iliaal | Date: | Fri, 03 Jul 2026 13:27:00 +0000 |
| Subject: | [php-src] PR #22576: Fix GH-22570: stack overflow serializing a deeply nested Dom\XMLDocument | ||
| Groups: | php.git-pulls | ||
| Request: | Send a blank email to git-pulls+get-36804@lists.php.net to get a copy of this message | ||
Pull Request: https://github.com/php/php-src/pull/22576
Author: iliaal
A deeply nested
Dom\XMLDocument overflows the C stack when serialized, since the XML
serializer recurses per element child. Adds a stack-limit check at the dispatcher (throwing an
Error on overflow, like bd724bd for var serialization) and gates the
saveXml warning and innerHTML exception with !EG(exception)
so the thrown Error isn't masked or replaced.
Fixes #22570