Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: JRuby 1.5.3
    • Fix Version/s: JRuby 1.6RC1
    • Component/s: Core Classes/Modules
    • Labels:
      None
    • Environment:
      any
    • Number of attachments :
      2

      Activity

      Hide
      Hiroki Kondo added a comment -

      I'm original reporter.
      The patch works for me.
      Thank you!

      Show
      Hiroki Kondo added a comment - I'm original reporter. The patch works for me. Thank you!
      Hide
      Hiroshi Nakamura added a comment -

      Applied at [master bc6ade404b8e530f823c] and [master a7d2e690ae3a701bfbb4].

      ant test & ant spec pass. The script at gist from the original reporter works for me.

      Show
      Hiroshi Nakamura added a comment - Applied at [master bc6ade404b8e530f823c] and [master a7d2e690ae3a701bfbb4] . ant test & ant spec pass. The script at gist from the original reporter works for me.
      Hide
      Koichiro Ohba added a comment -

      Added nkf test case.

      Show
      Koichiro Ohba added a comment - Added nkf test case.
      Hide
      Koichiro Ohba added a comment -

      Hi,
      Made NKF to decode all diffirent MIME-encoded parts in a string.

      Show
      Koichiro Ohba added a comment - Hi, Made NKF to decode all diffirent MIME-encoded parts in a string.
      Hide
      Hiroshi Nakamura added a comment -

      String#toutf8 defined in kconv module invokes NKF.nkf. NKF.nkf seems to handle only the first chunk of MIME-encoded string.

      See 'error' and 'expects' below.

      NKF.nkfが内部で呼ばれるが、デコード途中で文字列が切れてしまうパターン
      
      irb(main):001:0> source = "=?ISO-2022-JP?B?GyRCIXcbKEJJVBskQj83Q2VCLkpzGyhCIC0=?= =?ISO-2022-JP?B?IDIwMTAvOS8zGyRCISEbKEI=?= =?ISO-2022-JP?B?GyRCOkdNJUBoO3Y5YCRPIUhAZEJQJW0bKEI=?= =?ISO-2022-JP?B?GyRCITwlcyVBJDUkOyRrJDMkSCEqIUkbKEI=?="
      => "=?ISO-2022-JP?B?GyRCIXcbKEJJVBskQj83Q2VCLkpzGyhCIC0=?= =?ISO-2022-JP?B?IDIwMTAvOS8zGyRCISEbKEI=?= =?ISO-2022-JP?B?GyRCOkdNJUBoO3Y5YCRPIUhAZEJQJW0bKEI=?= =?ISO-2022-JP?B?GyRCITwlcyVBJDUkOyRrJDMkSCEqIUkbKEI=?="
      
      irb(main):002:0> require 'kconv'
      => true
      
      irb(main):003:0> source.toutf8()
      error:
      => "@IT新着速報 -"
      except:
      => "@IT新着速報 - 2010/9/3 最優先事項は"絶対ローンチさせること!""
      

      cf. http://gist.github.com/565852

      Show
      Hiroshi Nakamura added a comment - String#toutf8 defined in kconv module invokes NKF.nkf. NKF.nkf seems to handle only the first chunk of MIME-encoded string. See 'error' and 'expects' below. NKF.nkfが内部で呼ばれるが、デコード途中で文字列が切れてしまうパターン irb(main):001:0> source = "=?ISO-2022-JP?B?GyRCIXcbKEJJVBskQj83Q2VCLkpzGyhCIC0=?= =?ISO-2022-JP?B?IDIwMTAvOS8zGyRCISEbKEI=?= =?ISO-2022-JP?B?GyRCOkdNJUBoO3Y5YCRPIUhAZEJQJW0bKEI=?= =?ISO-2022-JP?B?GyRCITwlcyVBJDUkOyRrJDMkSCEqIUkbKEI=?=" => "=?ISO-2022-JP?B?GyRCIXcbKEJJVBskQj83Q2VCLkpzGyhCIC0=?= =?ISO-2022-JP?B?IDIwMTAvOS8zGyRCISEbKEI=?= =?ISO-2022-JP?B?GyRCOkdNJUBoO3Y5YCRPIUhAZEJQJW0bKEI=?= =?ISO-2022-JP?B?GyRCITwlcyVBJDUkOyRrJDMkSCEqIUkbKEI=?=" irb(main):002:0> require 'kconv' => true irb(main):003:0> source.toutf8() error: => "@IT新着速報 -" except: => "@IT新着速報 - 2010/9/3 最優先事項は"絶対ローンチさせること!"" cf. http://gist.github.com/565852

        People

        • Assignee:
          Hiroshi Nakamura
          Reporter:
          Hiroshi Nakamura
        • Votes:
          0 Vote for this issue
          Watchers:
          0 Start watching this issue

          Dates

          • Created:
            Updated:
            Resolved: