diff options
author | Aleksander Machniak <alec@alec.pl> | 2013-04-06 19:28:47 +0200 |
---|---|---|
committer | Aleksander Machniak <alec@alec.pl> | 2013-04-06 19:28:47 +0200 |
commit | 4fdaa02ac724e597479a4a48388a8a10101000fd (patch) | |
tree | ac6e7b739dddfafd41dde12c06ccbd6d82c29699 /program/steps | |
parent | 50cc5b370f1fab3ecf4ff516f60087129e8a57d1 (diff) |
Fix handling of invalid characters in message headers and output (#1489032)
Diffstat (limited to 'program/steps')
-rw-r--r-- | program/steps/mail/compose.inc | 8 | ||||
-rw-r--r-- | program/steps/mail/func.inc | 2 | ||||
-rw-r--r-- | program/steps/mail/show.inc | 2 |
3 files changed, 6 insertions, 6 deletions
diff --git a/program/steps/mail/compose.inc b/program/steps/mail/compose.inc index 36c6d9622..b787ca101 100644 --- a/program/steps/mail/compose.inc +++ b/program/steps/mail/compose.inc @@ -220,9 +220,9 @@ if (!empty($msg_uid) && empty($COMPOSE['as_attachment'])) } } else if ($compose_mode == RCUBE_COMPOSE_DRAFT) { - if ($MESSAGE->headers->others['x-draft-info']) { + if ($draft_info = $MESSAGE->headers->get('x-draft-info')) { // get reply_uid/forward_uid to flag the original message when sending - $info = rcmail_draftinfo_decode($MESSAGE->headers->others['x-draft-info']); + $info = rcmail_draftinfo_decode($draft_info); if ($info['type'] == 'reply') $COMPOSE['reply_uid'] = $info['uid']; @@ -239,8 +239,8 @@ if (!empty($msg_uid) && empty($COMPOSE['as_attachment'])) } } - if ($MESSAGE->headers->in_reply_to) - $COMPOSE['reply_msgid'] = '<'.$MESSAGE->headers->in_reply_to.'>'; + if ($in_reply_to = $MESSAGE->headers->get('in-reply-to')) + $COMPOSE['reply_msgid'] = '<' . $in_reply_to . '>'; $COMPOSE['references'] = $MESSAGE->headers->references; } diff --git a/program/steps/mail/func.inc b/program/steps/mail/func.inc index 274c40b5c..6333cf46d 100644 --- a/program/steps/mail/func.inc +++ b/program/steps/mail/func.inc @@ -896,7 +896,7 @@ function rcmail_washtml_callback($tagname, $attrib, $content, $washtml) * return table with message headers */ function rcmail_message_headers($attrib, $headers=null) - { +{ global $OUTPUT, $MESSAGE, $PRINT_MODE, $RCMAIL; static $sa_attrib; diff --git a/program/steps/mail/show.inc b/program/steps/mail/show.inc index 552c180f5..1947c0f29 100644 --- a/program/steps/mail/show.inc +++ b/program/steps/mail/show.inc @@ -109,7 +109,7 @@ if ($uid) { $OUTPUT->set_env('skip_deleted', true); if ($CONFIG['display_next']) $OUTPUT->set_env('display_next', true); - if ($MESSAGE->headers->others['list-post']) + if ($MESSAGE->headers->get('list-post', false)) $OUTPUT->set_env('list_post', true); if ($CONFIG['forward_attachment']) $OUTPUT->set_env('forward_attachment', true); |