mirror of
https://github.com/ruby/ruby.git
synced 2025-09-17 09:33:59 +02:00
merge revision(s) 40003: [Backport #7996]
* win32/file.c (code_page): use cp1252 instead of cp20127 as US-ASCII. fix [ruby-core:53079] [Bug #7996] reported and patched by mmeltner (Michael Meltner). reported by mitchellh (Mitchell Hashimoto). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@40293 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
5b2ea4e53b
commit
5525ff192c
3 changed files with 9 additions and 3 deletions
|
@ -212,9 +212,9 @@ code_page(rb_encoding *enc)
|
|||
names_ary = rb_funcall(encoding, names, 0);
|
||||
}
|
||||
|
||||
/* map US-ASCII and ASCII-8bit as code page 20127 (us-ascii) */
|
||||
/* map US-ASCII and ASCII-8bit as code page 1252 (us-ascii) */
|
||||
if (enc == rb_usascii_encoding() || enc == rb_ascii8bit_encoding()) {
|
||||
UINT code_page = 20127;
|
||||
UINT code_page = 1252;
|
||||
rb_hash_aset(rb_code_page, name_key, INT2FIX(code_page));
|
||||
return code_page;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue