Skip to content

Commit

Permalink
Fix issue where Content-Length of some attachments could be set to wr…
Browse files Browse the repository at this point in the history
…ong value causing browser errors (#1490482)
  • Loading branch information
alecpl committed Sep 10, 2015
1 parent 63e7937 commit 77be69f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ CHANGELOG Roundcube Webmail
- Fix so In-Reply-To header is set also for MDN receipts (#1490523)
- Fix missing HTTP_X_FORWARDED_FOR address in generated Received header
- Fix XSS issue in drag-n-drop file uploads (#1490530)
- Fix issue where Content-Length of some attachments could be set to wrong value causing browser errors (#1490482)

RELEASE 1.1.2
-------------
Expand Down
5 changes: 2 additions & 3 deletions program/steps/mail/get.inc
Original file line number Diff line number Diff line change
Expand Up @@ -359,9 +359,8 @@ else if (strlen($part_id)) {
$sent = true;
}
else if ($part->size) {
if ($size = (int)$part->d_parameters['size']) {
header("Content-Length: $size");
}
// Don't be tempted to set Content-Length to $part->d_parameters['size'] (#1490482)
// RFC2183 says "The size parameter indicates an approximate size"

$sent = $MESSAGE->get_part_body($part->mime_id, false, 0, -1);
}
Expand Down

0 comments on commit 77be69f

Please sign in to comment.