diff options
author | rhe <rhe@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-12-14 12:32:42 +0000 |
---|---|---|
committer | rhe <rhe@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-12-14 12:32:42 +0000 |
commit | 201972ac4cf81d12a7018308b9e88400c5e61a9d (patch) | |
tree | b0ec70120b2220abf742bcc994dac9a71d244038 /win32/mkexports.rb | |
parent | 72c1b322c7ff86c4ddc6370cb6e405032ff21545 (diff) | |
download | ruby-201972ac4cf81d12a7018308b9e88400c5e61a9d.tar.gz |
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]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57078 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'win32/mkexports.rb')
0 files changed, 0 insertions, 0 deletions