From cf121785f2fed866150a493b035c3ea987a8ba9f Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tim=20D=C3=BCsterhus?= Date: Wed, 15 May 2013 21:24:37 +0200 Subject: [PATCH] Properly handle CRLF in ExceptionLogViewPage --- .../install/files/lib/acp/page/ExceptionLogViewPage.class.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/wcfsetup/install/files/lib/acp/page/ExceptionLogViewPage.class.php b/wcfsetup/install/files/lib/acp/page/ExceptionLogViewPage.class.php index 7c0547dcdd..8b46f8e361 100644 --- a/wcfsetup/install/files/lib/acp/page/ExceptionLogViewPage.class.php +++ b/wcfsetup/install/files/lib/acp/page/ExceptionLogViewPage.class.php @@ -103,6 +103,9 @@ class ExceptionLogViewPage extends MultipleLinkPage { return; } + // unify newlines + $contents = StringUtil::unifyNewlines($contents); + // split contents $split = new Regex('(?:^|\n<<<<\n\n)(?:<<<<<<<<([a-f0-9]{40})<<<<\n|$)'); $contents = $split->split($contents, Regex::SPLIT_NON_EMPTY_ONLY | Regex::CAPTURE_SPLIT_DELIMITER); -- 2.20.1