From: Shugo Maeda Date: 1997-10-23T14:38:49+09:00 Subject: [ruby-list:5115] Re: mime.rb ver 0.5 (Re: mail address class) --NeXT-Mail-1294785100-2 Content-Type: text/enriched; charset=iso-2022-jp Content-Transfer-Encoding: 7bit Content-Disposition: inline 前田です。 On Thu, 23 Oct 97 14:12:14 +0900 Shugo Maeda < wrote: > 書き直したmime.rbをこのメールに添付します。 すみません、バグってました。 パッチです。 --- 前田 修吾 --NeXT-Mail-1294785100-2 Content-Type: application/octet-stream; name=mime.rb.diff; x-unix-mode=0644 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=mime.rb.diff --- mime.rb.orig Thu Oct 23 14:22:30 1997 +++ mime.rb Thu Oct 23 14:24:33 1997 @@ -109,7 +109,12 @@ end params = {} split_tokens(tokens, ";").each do |ary| - if ary.length == 2 and ary[0] =~ /=$/ + if ary.length == 1 and ary[0] =~ /=/ + tmp = ary[0].split("=") + attribute = tmp.shift.downcase + value = tmp.join + params[attribute] = value + elsif ary.length == 2 and ary[0] =~ /=$/ attribute = ary[0].chop.downcase value = ary[1] if value[0] == ?" and value[-1] == ?" --NeXT-Mail-1294785100-2--