[wp-trac] [WordPress Trac] #59233: Improve error handling for unserialize()

WordPress Trac noreply at wordpress.org
Mon Jul 21 23:31:01 UTC 2025


#59233: Improve error handling for unserialize()
-----------------------------+-----------------------------
 Reporter:  jrf              |       Owner:  (none)
     Type:  task (blessed)   |      Status:  new
 Priority:  normal           |   Milestone:  Future Release
Component:  General          |     Version:
 Severity:  normal           |  Resolution:
 Keywords:  php83 has-patch  |     Focuses:
-----------------------------+-----------------------------

Comment (by dmsnell):

 Apologies for the immediate follow-up, but one thing that passing in a
 `&$did_unserialize` argument could enable is skipping the check for
 `is_serialized()` which seems like it is guaranteed to fail in certain
 cases as serialization forms change. Maybe this could happen anyway, but
 the check of a user-defined `is_serialized()` seems unnecessary when we
 know that `unserialize()` will report if it fails.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/59233#comment:13>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list