summaryrefslogtreecommitdiff
path: root/program/include
diff options
context:
space:
mode:
authoralecpl <alec@alec.pl>2008-06-12 13:38:24 +0000
committeralecpl <alec@alec.pl>2008-06-12 13:38:24 +0000
commit60881e5a147a367dbb788f67167c659fb738dc36 (patch)
tree92dad61fcbe1661799365bb26d475365d52d7efd /program/include
parentac6e28409fd69ad57865c0fa184f96e0df82b068 (diff)
- Fix corrupted MIME headers of messages in Sent folder (#1485111)
Diffstat (limited to 'program/include')
-rw-r--r--program/include/rcube_mail_mime.php18
1 files changed, 18 insertions, 0 deletions
diff --git a/program/include/rcube_mail_mime.php b/program/include/rcube_mail_mime.php
index 866786b93..79c80dd69 100644
--- a/program/include/rcube_mail_mime.php
+++ b/program/include/rcube_mail_mime.php
@@ -27,6 +27,9 @@
*/
class rcube_mail_mime extends Mail_mime
{
+
+ protected $mime_content;
+
/**
* Set build parameters
*/
@@ -201,6 +204,21 @@ class rcube_mail_mime extends Mail_mime
$result[] = substr($string, $p);
return $result;
}
+
+ /**
+ * Provides caching of body of constructed MIME Message to avoid
+ * duplicate construction of message and damage of MIME headers
+ *
+ * @return string The mime content
+ * @access public
+ * @override
+ */
+ public function &get($build_params = null)
+ {
+ if(empty($this->mime_content))
+ $this->mime_content = parent::get($build_params);
+ return $this->mime_content;
+ }
}