mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* encoding.c (rb_enc_get_index): don't return -1.
* io.c (rb_scan_open_args): call FilePathValue before encoding conversion. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19362 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
db14bfe4ea
commit
a517395056
3 changed files with 9 additions and 1 deletions
|
@ -1,3 +1,10 @@
|
|||
Mon Sep 15 23:28:28 2008 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* encoding.c (rb_enc_get_index): don't return -1.
|
||||
|
||||
* io.c (rb_scan_open_args): call FilePathValue before encoding
|
||||
conversion.
|
||||
|
||||
Mon Sep 15 20:57:00 2008 Yuki Sonoda (Yugui) <yugui@yugui.jp>
|
||||
|
||||
* lib/matrix.rb (Matrix#eql?): fixed [ruby-dev:36298].
|
||||
|
|
|
@ -549,6 +549,7 @@ rb_enc_get_index(VALUE obj)
|
|||
VALUE tmp;
|
||||
|
||||
switch (BUILTIN_TYPE(obj)) {
|
||||
default:
|
||||
case T_STRING:
|
||||
case T_REGEXP:
|
||||
i = ENCODING_GET_INLINED(obj);
|
||||
|
|
2
io.c
2
io.c
|
@ -4631,6 +4631,7 @@ rb_scan_open_args(int argc, VALUE *argv,
|
|||
opt = pop_last_hash(&argc, &argv);
|
||||
|
||||
rb_scan_args(argc, argv, "12", &fname, &vmode, &vperm);
|
||||
FilePathValue(fname);
|
||||
#if defined _WIN32 || defined __APPLE__
|
||||
{
|
||||
static rb_encoding *fs_encoding;
|
||||
|
@ -4650,7 +4651,6 @@ rb_scan_open_args(int argc, VALUE *argv,
|
|||
}
|
||||
}
|
||||
#endif
|
||||
FilePathValue(fname);
|
||||
|
||||
rb_io_extract_modeenc(&vmode, opt, &oflags, &fmode, convconfig_p);
|
||||
|
||||
|
|
Loading…
Reference in a new issue