From: Pierre Joye Date: Thu, 18 Mar 2004 15:14:02 +0000 (+0000) Subject: - Test for possible data corruption with __set X-Git-Tag: php-5.0.0RC2RC1~307 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3d331bc64c908531d6177295e68eea2f904f04ae;p=php - Test for possible data corruption with __set --- diff --git a/tests/classes/__set_data_corrupt.phpt b/tests/classes/__set_data_corrupt.phpt new file mode 100644 index 0000000000..86c39243d5 --- /dev/null +++ b/tests/classes/__set_data_corrupt.phpt @@ -0,0 +1,29 @@ +--TEST-- +Data corruption in __set +--SKIPIF-- + +--FILE-- +null); + + function bar() { + echo $this->t ='f'; + } + function __get($prop) + { + return $this->pp[$prop]; + } + function __set($prop, $val) + { + echo "__set"; + $this->pp[$prop] = ''; + } +} +$f = new foo; +$f->bar(); +?> +--EXPECT-- +__setf