mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* io.c (rb_open_file): fs_encoding and fname_encoding is
rb_encoding *. fixed [ruby-dev:35151] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17403 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
a966b61fd2
commit
58d694fcdb
2 changed files with 8 additions and 1094 deletions
4
io.c
4
io.c
|
@ -4104,8 +4104,8 @@ rb_open_file(int argc, VALUE *argv, VALUE io)
|
|||
rb_scan_args(argc, argv, "12", &fname, &vmode, &perm);
|
||||
#if defined _WIN32 || defined __APPLE__
|
||||
{
|
||||
static int fs_encoding;
|
||||
int fname_encoding = rb_enc_get(fname);
|
||||
static rb_encoding *fs_encoding;
|
||||
rb_encoding *fname_encoding = rb_enc_get(fname);
|
||||
if (!fs_encoding)
|
||||
fs_encoding = rb_filesystem_encoding();
|
||||
if (rb_usascii_encoding() != fname_encoding
|
||||
|
|
Loading…
Reference in a new issue