]> granicus.if.org Git - php/commit
Add optional second arg to unserialize()
authorSara Golemon <pollita@php.net>
Thu, 16 May 2013 21:37:36 +0000 (14:37 -0700)
committerSara Golemon <pollita@php.net>
Thu, 16 May 2013 22:18:35 +0000 (15:18 -0700)
commitcfd104582220d578ab1b78a5991065d038e1f931
tree2e1de428adfc10e1235de637d72a81cdebacbfa3
parentbc656cde0453aa6de50812ba9edfc6f74c61ce37
Add optional second arg to unserialize()

Returns the number of bytes consumed by reference for
streaming unserialization.

Actual unserialization behavior is not modified at all.

The need for this came up while trying to parse SplDoublyLinkedList's
serialization format which uses a non-standard stream of serialized values.
ext/standard/basic_functions.c
ext/standard/tests/serialize/serialization_error_001.phpt
ext/standard/tests/serialize/unserialize_consumed.phpt [new file with mode: 0644]
ext/standard/var.c