Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[HttpFoundation] tweaked previous merge
  • Loading branch information
fabpot committed Jul 15, 2012
1 parent 4513210 commit d7a5449
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/Symfony/Component/HttpFoundation/Response.php
Expand Up @@ -300,7 +300,11 @@ public function send()
if (function_exists('fastcgi_finish_request')) {
fastcgi_finish_request();
} else {
while (0 < ob_get_level()) {
// ob_get_level() never returns 0 on some Windows configurations, so if
// the level is the same two times in a row, the loop should be stopped.
$previous = null;
while (($level = ob_get_level()) > 0 && $level !== $previous) {
$previous = $level;
ob_end_flush();
}
flush();
Expand Down

0 comments on commit d7a5449

Please sign in to comment.