From 68c41f1dff4ec94ffa78ef772cd1bcd3f8d2d9a0 Mon Sep 17 00:00:00 2001
From: Aleksander Machniak <alec@alec.pl>
Date: Tue, 28 Oct 2014 04:06:29 -0400
Subject: [PATCH] Fix regresion that caused double charset conversion in some messages (#1490121)

---
 program/lib/Roundcube/rcube_text2html.php |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/program/lib/Roundcube/rcube_text2html.php b/program/lib/Roundcube/rcube_text2html.php
index 46c2b7e..0afc6d1 100644
--- a/program/lib/Roundcube/rcube_text2html.php
+++ b/program/lib/Roundcube/rcube_text2html.php
@@ -57,6 +57,8 @@
         'end'    => '</div>',
         // enables links replacement
         'links'  => true,
+        // string replacer class
+        'replacer' => 'rcube_string_replacer',
     );
 
 
@@ -141,7 +143,7 @@
     {
         // make links and email-addresses clickable
         $attribs  = array('link_attribs' => array('rel' => 'noreferrer', 'target' => '_blank'));
-        $replacer = new rcmail_string_replacer($attribs);
+        $replacer = new $this->config['replacer']($attribs);
 
         if ($this->config['flowed']) {
             $flowed_char = 0x01;

--
Gitblit v1.9.1