From 21461dce77dd67a45a22e361dca4ecaf6c580788 Mon Sep 17 00:00:00 2001 From: alecpl Date: Mon, 16 May 2011 07:13:01 +0000 Subject: - Trim HTML message before washing, to make sure that BOM is removed even when prepended by some whitespace chars (#1487915) --- program/steps/mail/func.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'program/steps/mail') diff --git a/program/steps/mail/func.inc b/program/steps/mail/func.inc index cfdad791a..36b4c02a6 100644 --- a/program/steps/mail/func.inc +++ b/program/steps/mail/func.inc @@ -575,7 +575,7 @@ function rcmail_wash_html($html, $p = array(), $cid_replaces) '', '', ); - $html = preg_replace($html_search, $html_replace, $html); + $html = preg_replace($html_search, $html_replace, trim($html)); // PCRE errors handling (#1486856), should we use something like for every preg_* use? if ($html === null && ($preg_error = preg_last_error()) != PREG_NO_ERROR) { -- cgit v1.2.3