* ruby.c (process_options): -K and -E in shebang should be reflect to
default_external. [ruby-dev:37920] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22085 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
1bd6111488
commit
5067bfe36e
@ -1,3 +1,8 @@
|
|||||||
|
Fri Feb 6 12:03:47 2009 NAKAMURA Usaku <usa@ruby-lang.org>
|
||||||
|
|
||||||
|
* ruby.c (process_options): -K and -E in shebang should be reflect to
|
||||||
|
default_external. [ruby-dev:37920]
|
||||||
|
|
||||||
Fri Feb 6 07:52:57 2009 Tanaka Akira <akr@fsij.org>
|
Fri Feb 6 07:52:57 2009 Tanaka Akira <akr@fsij.org>
|
||||||
|
|
||||||
* ext/pty/pty.c (chfunc): type fixed.
|
* ext/pty/pty.c (chfunc): type fixed.
|
||||||
|
14
ruby.c
14
ruby.c
@ -1296,13 +1296,6 @@ process_options(VALUE arg)
|
|||||||
opt->src.enc.index = opt_enc_index(opt->src.enc.name);
|
opt->src.enc.index = opt_enc_index(opt->src.enc.name);
|
||||||
src_encoding_index = opt->src.enc.index;
|
src_encoding_index = opt->src.enc.index;
|
||||||
}
|
}
|
||||||
if (opt->ext.enc.index >= 0) {
|
|
||||||
enc = rb_enc_from_index(opt->ext.enc.index);
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
enc = lenc;
|
|
||||||
}
|
|
||||||
rb_enc_set_default_external(rb_enc_from_encoding(enc));
|
|
||||||
if (opt->intern.enc.index >= 0) {
|
if (opt->intern.enc.index >= 0) {
|
||||||
enc = rb_enc_from_index(opt->intern.enc.index);
|
enc = rb_enc_from_index(opt->intern.enc.index);
|
||||||
rb_enc_set_default_internal(rb_enc_from_encoding(enc));
|
rb_enc_set_default_internal(rb_enc_from_encoding(enc));
|
||||||
@ -1363,6 +1356,13 @@ process_options(VALUE arg)
|
|||||||
}
|
}
|
||||||
if (opt->dump & DUMP_BIT(yydebug)) return Qtrue;
|
if (opt->dump & DUMP_BIT(yydebug)) return Qtrue;
|
||||||
|
|
||||||
|
if (opt->ext.enc.index >= 0) {
|
||||||
|
enc = rb_enc_from_index(opt->ext.enc.index);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
enc = lenc;
|
||||||
|
}
|
||||||
|
rb_enc_set_default_external(rb_enc_from_encoding(enc));
|
||||||
if (opt->intern.enc.index >= 0) {
|
if (opt->intern.enc.index >= 0) {
|
||||||
/* Set in the shebang line */
|
/* Set in the shebang line */
|
||||||
enc = rb_enc_from_index(opt->intern.enc.index);
|
enc = rb_enc_from_index(opt->intern.enc.index);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user