summaryrefslogtreecommitdiff
path: root/program/lib/Roundcube
diff options
context:
space:
mode:
authorAleksander Machniak <alec@alec.pl>2013-12-21 14:49:00 +0100
committerAleksander Machniak <alec@alec.pl>2013-12-21 14:49:00 +0100
commit54029ea959b5f59447e3f0a01a453fd5fe0ba8fa (patch)
treeb8c0bb5864210064407ecd94ed77cd4fd617af5e /program/lib/Roundcube
parent5224a6b39423c70da844638f09fde423944578a2 (diff)
Fix broken text/* attachments when forwarding/editing a message (#1489426)
Diffstat (limited to 'program/lib/Roundcube')
-rw-r--r--program/lib/Roundcube/rcube_imap.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/program/lib/Roundcube/rcube_imap.php b/program/lib/Roundcube/rcube_imap.php
index dc5305808..f1363caf7 100644
--- a/program/lib/Roundcube/rcube_imap.php
+++ b/program/lib/Roundcube/rcube_imap.php
@@ -2121,7 +2121,7 @@ class rcube_imap extends rcube_storage
// convert charset (if text or message part)
if ($body && preg_match('/^(text|message)$/', $o_part->ctype_primary)) {
// Remove NULL characters if any (#1486189)
- if (strpos($body, "\x00") !== false) {
+ if ($formatted && strpos($body, "\x00") !== false) {
$body = str_replace("\x00", '', $body);
}