]> git.cworth.org Git - sup/commitdiff
content-type parsing bugfix thanks to Nicolas Pouillard
authorwmorgan <wmorgan@5c8cc53c-5e98-4d25-b20a-d8db53a31250>
Thu, 26 Jul 2007 05:56:04 +0000 (05:56 +0000)
committerwmorgan <wmorgan@5c8cc53c-5e98-4d25-b20a-d8db53a31250>
Thu, 26 Jul 2007 05:56:04 +0000 (05:56 +0000)
git-svn-id: svn://rubyforge.org/var/svn/sup/trunk@509 5c8cc53c-5e98-4d25-b20a-d8db53a31250

lib/sup/message.rb

index c8282ffa6a3b71a52a72a711b4de07a066cde548..850c5584c70f3d7bc1b335cad9464a8b8358c765 100644 (file)
@@ -325,7 +325,7 @@ private
 
   def self.decode_and_convert m
     charset =
-      if m.header.field?("content-type") && m.header.fetch("content-type") =~ /charset=(.*?)(;|$)/
+      if m.header.field?("content-type") && m.header.fetch("content-type") =~ /charset="?(.*?)"?(;|$)/
         $1
       end