diff --git a/ChangeLog b/ChangeLog index 2350379d1..5410de07e 100755 --- a/ChangeLog +++ b/ChangeLog @@ -10,6 +10,8 @@ $Source$ * libraries/import.lib.php: Correctly fail if file is too short (bug #1574340). * libraries/db_table_exists.lib.php: Fix displaying of entered query. + * libraries/common.lib.php: Check for sent headers, provide backtrace in + this case. 2006-10-09 Michal Čihař * lang/german: Fix typo (translation #1570611). diff --git a/libraries/common.lib.php b/libraries/common.lib.php index 470f68d1f..89a3305e9 100644 --- a/libraries/common.lib.php +++ b/libraries/common.lib.php @@ -928,6 +928,14 @@ if (!defined('PMA_MINIMUM_COMMON')) { } } else { session_write_close(); + if (headers_sent()) { + if (function_exists(debug_print_backtrace)) { + echo '
';
+                        debug_print_backtrace();
+                        echo '
'; + } + trigger_error('PMA_sendHeaderLocation called when headers are already sent!', E_USER_ERROR); + } // bug #1523784: IE6 does not like 'Refresh: 0', it // results in a blank page // but we need it when coming from the cookie login panel)