Return to bug53903.phpt CVS log | Up to [ELWIX - Embedded LightWeight unIX -] / embedaddon / php / ext / standard / tests / streams |
1.1 misho 1: --TEST-- 2: Bug #53903 streamwrapper/stream_stat causes problems 3: --FILE-- 4: <?php 5: 6: class sw { 7: 8: public function stream_open($path, $mode, $options, &$opened_path) { 9: return true; 10: } 11: 12: public function stream_stat() { 13: return array( 14: 'atime' => $this->undefined, 15: ); 16: } 17: 18: } 19: stream_wrapper_register('sx', 'sw') or die('failed'); 20: 21: fstat(fopen('sx://test', 'r')); 22: 23: $s[] = 1; // Cannot use a scalar value as an array 24: 25: print_r($s); 26: --EXPECTF-- 27: Notice: Undefined property: sw::$undefined in %s on line %d 28: Array 29: ( 30: [0] => 1 31: ) 32: