[ruby-cvs:64383] usa:r57217 (ruby_2_2): merge revision(s) 57078: [Backport #13034]

usa at ruby-lang.org usa at ruby-lang.org
Tue Dec 27 19:52:36 JST 2016


usa	2016-12-27 19:52:35 +0900 (Tue, 27 Dec 2016)

  New Revision: 57217

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=57217

  Log:
    merge revision(s) 57078: [Backport #13034]
    
    encoding.c: handle needmore error from rb_enc_precise_mbclen()
    
    rb_enc_ascget() erroneously reports success even if the given byte
    sequence is incomplete, for non-ASCII compatible encoding strings.
    
    rb_enc_precise_mbclen() may return a negative value on error, and thus
    rb_enc_ascget() must not store the return value in 'unsigned int';
    otherwise the subsequent MBCLEN_CHARFOUND_P() check won't catch the
    error.  [ruby-core:78646] [Bug #13034]

  Modified directories:
    branches/ruby_2_2/
  Modified files:
    branches/ruby_2_2/ChangeLog
    branches/ruby_2_2/encoding.c
    branches/ruby_2_2/test/ruby/test_regexp.rb
    branches/ruby_2_2/version.h


More information about the ruby-cvs mailing list