From 021a12edf6e7bd9981cb167960cd4776b5bd0af8 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Mon, 20 Apr 2009 20:35:31 +0000 Subject: [PATCH] Fix warning in wp_ob_end_flush_all(). Props richcon. fixes #5109 git-svn-id: https://develop.svn.wordpress.org/trunk@11020 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/functions.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/wp-includes/functions.php b/wp-includes/functions.php index 2ed1791a48..86080d677d 100644 --- a/wp-includes/functions.php +++ b/wp-includes/functions.php @@ -2657,7 +2657,9 @@ function wp_widgets_add_menu() { * @since 2.2.0 */ function wp_ob_end_flush_all() { - while ( @ob_end_flush() ); + $levels = ob_get_level(); + for ($i=0; $i<$levels; $i++) + ob_end_flush(); } /**