From: Michael M Slusarz Date: Fri, 7 Aug 2009 19:03:00 +0000 (-0600) Subject: Better way to check for unexpected output X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=62bd4cae4ffd9d9376558a6210690d226645335c;p=horde.git Better way to check for unexpected output --- diff --git a/imp/ajax.php b/imp/ajax.php index 3bb8af30c..a04b59816 100644 --- a/imp/ajax.php +++ b/imp/ajax.php @@ -795,10 +795,8 @@ case 'FetchmailDialog': // Clear the output buffer that we started above, and log any unexpected // output at a DEBUG level. -$errors = ob_get_clean(); -if ($errors) { - Horde::logMessage('DIMP: unexpected output: ' . - $errors, __FILE__, __LINE__, PEAR_LOG_DEBUG); +if (ob_get_length()) { + Horde::logMessage('DIMP: unexpected output: ' . ob_get_clean(), __FILE__, __LINE__, PEAR_LOG_DEBUG); } // Send the final result.