File:
[ELWIX - Embedded LightWeight unIX -] /
embedaddon /
php /
tests /
lang /
bug30578.phpt
Revision
1.1.1.1 (vendor branch):
download - view:
text,
annotated -
select for diffs -
revision graph
Tue Feb 21 23:48:06 2012 UTC (12 years, 5 months ago) by
misho
Branches:
php,
MAIN
CVS tags:
v5_4_3elwix,
v5_4_29p0,
v5_4_29,
v5_4_20p0,
v5_4_20,
v5_4_17p0,
v5_4_17,
v5_3_10,
HEAD
php
1: --TEST--
2: Bug #30578 (Output buffers flushed before calling __desctruct functions)
3: --FILE--
4: <?php
5:
6: error_reporting(E_ALL);
7:
8: class Example
9: {
10: function __construct()
11: {
12: ob_start();
13: echo "This should be displayed last.\n";
14: }
15:
16: function __destruct()
17: {
18: $buffered_data = ob_get_contents();
19: ob_end_clean();
20:
21: echo "This should be displayed first.\n";
22: echo "Buffered data: $buffered_data";
23: }
24: }
25:
26: $obj = new Example;
27:
28: ?>
29: --EXPECT--
30: This should be displayed first.
31: Buffered data: This should be displayed last.
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>