diff options
author | Aleksander Machniak <alec@alec.pl> | 2013-01-21 12:00:24 +0100 |
---|---|---|
committer | Aleksander Machniak <alec@alec.pl> | 2013-01-21 12:02:44 +0100 |
commit | 68fb9e63f06d43e4c07d4a57fd153de2ce8474b0 (patch) | |
tree | 355f5f5b0bc78cb8ddbf6fd75e57274882de52d3 /program/lib | |
parent | 9deb663f94e9819e9a0b5c6bb2026e1e37bac5e3 (diff) |
Rtrim() quoted lines on conversion to flowed format (according to RFC2646)
Diffstat (limited to 'program/lib')
-rw-r--r-- | program/lib/Roundcube/rcube_mime.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/program/lib/Roundcube/rcube_mime.php b/program/lib/Roundcube/rcube_mime.php index e9d5cf148..2f24a1bb3 100644 --- a/program/lib/Roundcube/rcube_mime.php +++ b/program/lib/Roundcube/rcube_mime.php @@ -544,8 +544,8 @@ class rcube_mime if ($line[0] == '>') { // remove quote chars, store level in $level $line = preg_replace('/^>+/', '', $line, -1, $level); - // remove (optional) space-staffing - $line = preg_replace('/^ /', '', $line); + // remove (optional) space-staffing and spaces before the line end + $line = preg_replace('/(^ | +$)/', '', $line); $prefix = str_repeat('>', $level) . ' '; $line = $prefix . self::wordwrap($line, $length - $level - 2, " \r\n$prefix", false, $charset); } |