diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2005-03-26 13:14:54 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2005-03-26 13:14:54 +0000 |
commit | 87b1d3834f135390375f2fa06e9b2a22ade0b5cb (patch) | |
tree | 27820e0ae0b55153fd49c9e9fcca54c6210ec464 /actionmailer | |
parent | df7a4d498c542a57d99622e160b3ede3d8b688a9 (diff) | |
download | rails-87b1d3834f135390375f2fa06e9b2a22ade0b5cb.tar.gz rails-87b1d3834f135390375f2fa06e9b2a22ade0b5cb.tar.bz2 rails-87b1d3834f135390375f2fa06e9b2a22ade0b5cb.zip |
Fixed that if charset was found that the end of a mime part declaration TMail would throw an error #919 [lon@speedymac.com] Fixed that TMail::Unquoter would fail to recognize quoting method if it was in lowercase #919 [lon@speedymac.com] Fixed that TMail::Encoder would fail when it attempts to parse e-mail addresses which are encoded using something other than the messages encoding method #919 [lon@speedymac.com]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@997 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionmailer')
-rw-r--r-- | actionmailer/CHANGELOG | 6 | ||||
-rwxr-xr-x | actionmailer/lib/action_mailer/vendor/tmail/encode.rb | 2 | ||||
-rwxr-xr-x | actionmailer/lib/action_mailer/vendor/tmail/mail.rb | 2 | ||||
-rw-r--r-- | actionmailer/lib/action_mailer/vendor/tmail/quoting.rb | 2 |
4 files changed, 10 insertions, 2 deletions
diff --git a/actionmailer/CHANGELOG b/actionmailer/CHANGELOG index d43d2e326e..14ceb687e7 100644 --- a/actionmailer/CHANGELOG +++ b/actionmailer/CHANGELOG @@ -1,5 +1,11 @@ *SVN* +* Fixed that if charset was found that the end of a mime part declaration TMail would throw an error #919 [lon@speedymac.com] + +* Fixed that TMail::Unquoter would fail to recognize quoting method if it was in lowercase #919 [lon@speedymac.com] + +* Fixed that TMail::Encoder would fail when it attempts to parse e-mail addresses which are encoded using something other than the messages encoding method #919 [lon@speedymac.com] + * Added rescue for missing iconv library and throws warnings if subject/body is called on a TMail object without it instead diff --git a/actionmailer/lib/action_mailer/vendor/tmail/encode.rb b/actionmailer/lib/action_mailer/vendor/tmail/encode.rb index 8f33386f4d..c0909f30d2 100755 --- a/actionmailer/lib/action_mailer/vendor/tmail/encode.rb +++ b/actionmailer/lib/action_mailer/vendor/tmail/encode.rb @@ -295,7 +295,7 @@ module TMail else raise 'TMail FATAL: encoder scan fail' end - str = m.post_match + (str = m.post_match) unless m.nil? end do_encode types, strs diff --git a/actionmailer/lib/action_mailer/vendor/tmail/mail.rb b/actionmailer/lib/action_mailer/vendor/tmail/mail.rb index 5aa111ad1f..22bc8edcca 100755 --- a/actionmailer/lib/action_mailer/vendor/tmail/mail.rb +++ b/actionmailer/lib/action_mailer/vendor/tmail/mail.rb @@ -281,6 +281,8 @@ module TMail when /\AFrom (\S+)/ unixfrom = $1 + when /^charset=.*/ + else raise SyntaxError, "wrong mail header: '#{line.inspect}'" end diff --git a/actionmailer/lib/action_mailer/vendor/tmail/quoting.rb b/actionmailer/lib/action_mailer/vendor/tmail/quoting.rb index f4f2463e34..626e88238f 100644 --- a/actionmailer/lib/action_mailer/vendor/tmail/quoting.rb +++ b/actionmailer/lib/action_mailer/vendor/tmail/quoting.rb @@ -35,7 +35,7 @@ begin from_charset = $1 quoting_method = $2 text = $3 - case quoting_method + case quoting_method.upcase when "Q" then unquote_quoted_printable_and_convert_to(text, from_charset, to_charset) when "B" then |