1--TEST--
2Object serialization / unserialization: Strict format (2)
3--FILE--
4<?php
5class A implements Serializable {
6	public function serialize() {}
7	public function unserialize($data) {}
8	public function __serialize() {}
9	public function __unserialize($data) {}
10}
11
12var_dump(unserialize('C:1:"A":3x{foo}'));
13                    //012345678901234
14var_dump(unserialize('C:1:"A":3:xfoo}'));
15                    //012345678901234
16var_dump(unserialize('C:1:"A":3:{foox'));
17                    //012345678901234
18var_dump(unserialize('C:1:"A":'));
19                    //01234567
20
21?>
22--EXPECTF--
23Warning: unserialize(): Error at offset 9 of 15 bytes in %s on line %d
24bool(false)
25
26Warning: unserialize(): Error at offset 10 of 15 bytes in %s on line %d
27bool(false)
28
29Warning: unserialize(): Error at offset 14 of 15 bytes in %s on line %d
30bool(false)
31
32Warning: unserialize(): Error at offset 8 of 8 bytes in %s on line %d
33bool(false)
34