1--TEST--
2Bug #71995 (Returning the same var twice from __sleep() produces broken serialized data)
3--FILE--
4<?php
5
6class A {
7    public $b;
8    public function __construct() {
9        $this->b = new StdClass();
10    }
11    public  function __sleep() {
12        return array("b", "b");
13    }
14}
15$a = new A();
16$s = serialize($a);
17var_dump($s);
18var_dump(unserialize($s));
19?>
20--EXPECTF--
21Warning: serialize(): "b" is returned from __sleep() multiple times in %s on line %d
22string(39) "O:1:"A":1:{s:1:"b";O:8:"stdClass":0:{}}"
23object(A)#%d (1) {
24  ["b"]=>
25  object(stdClass)#%d (0) {
26  }
27}
28