From 7cccd59cdc0f89d13b57c1aacad72dc5687dd453 Mon Sep 17 00:00:00 2001 From: Oliver Schramm Date: Sat, 5 Apr 2014 19:48:52 +0200 Subject: [ticket/12193] Fix broken HTML if SQL error occurs during migration PHPBB3-12193 --- phpBB/includes/functions.php | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'phpBB/includes/functions.php') diff --git a/phpBB/includes/functions.php b/phpBB/includes/functions.php index 8c29bc7171..ef17076def 100644 --- a/phpBB/includes/functions.php +++ b/phpBB/includes/functions.php @@ -3849,6 +3849,16 @@ function msg_handler($errno, $msg_text, $errfile, $errline) if (defined('IN_INSTALL') || defined('DEBUG') || isset($auth) && $auth->acl_get('a_')) { $msg_text = $log_text; + + // If this is defined there already was some output + // So let's not break it + if (defined('IN_DB_UPDATE')) + { + echo '
' . $msg_text . '
'; + + $db->sql_return_on_error(true); + phpbb_end_update($cache, $config); + } } if ((defined('IN_CRON') || defined('IMAGE_OUTPUT')) && isset($db)) -- cgit v1.2.1