From 0c1ae1b5324fa10f96129c5679b788cc1ca9468e Mon Sep 17 00:00:00 2001 From: Bob Weinand Date: Sun, 13 Nov 2016 18:52:50 +0100 Subject: [PATCH] Correct fix for #1956 --- src/Util/PHP/Template/TestCaseMethod.tpl.dist | 2 +- src/Util/PHP/eval-stdin.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Util/PHP/Template/TestCaseMethod.tpl.dist b/src/Util/PHP/Template/TestCaseMethod.tpl.dist index 47ef6e48a60..c7172b9d887 100644 --- a/src/Util/PHP/Template/TestCaseMethod.tpl.dist +++ b/src/Util/PHP/Template/TestCaseMethod.tpl.dist @@ -58,7 +58,7 @@ function __phpunit_run_isolated_test() $output = $test->getActualOutput(); } - rewind(STDOUT); + @rewind(STDOUT); /* @ as not every STDOUT target stream is rewindable */ if ($stdout = stream_get_contents(STDOUT)) { $output = $stdout . $output; } diff --git a/src/Util/PHP/eval-stdin.php b/src/Util/PHP/eval-stdin.php index fe1b8bd38d2..3b3a6d03c4d 100644 --- a/src/Util/PHP/eval-stdin.php +++ b/src/Util/PHP/eval-stdin.php @@ -1,3 +1,3 @@ ' . file_get_contents('php://input')); +eval('?>' . file_get_contents('php://stdin'));