mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* ext/readline/readline.c (readline_readline): check if instream
is closed instead of fd 0. * ext/readline/readline.c (Init_readline): use STDIN for input. http://d.hatena.ne.jp/codnote/20100111/1263174134 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26300 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
8f3f9d715f
commit
0d354933c5
2 changed files with 12 additions and 2 deletions
10
ChangeLog
10
ChangeLog
|
@ -1,3 +1,11 @@
|
||||||
|
Tue Jan 12 16:48:03 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
|
* ext/readline/readline.c (readline_readline): check if instream
|
||||||
|
is closed instead of fd 0.
|
||||||
|
|
||||||
|
* ext/readline/readline.c (Init_readline): use STDIN for input.
|
||||||
|
http://d.hatena.ne.jp/codnote/20100111/1263174134
|
||||||
|
|
||||||
Tue Jan 12 16:09:02 2010 wanabe <s.wanabe@gmail.com>
|
Tue Jan 12 16:09:02 2010 wanabe <s.wanabe@gmail.com>
|
||||||
|
|
||||||
* test/ruby/test_process.rb (test_execopts_env): MANDATORY_ENVS might
|
* test/ruby/test_process.rb (test_execopts_env): MANDATORY_ENVS might
|
||||||
|
@ -5,7 +13,7 @@ Tue Jan 12 16:09:02 2010 wanabe <s.wanabe@gmail.com>
|
||||||
|
|
||||||
Tue Jan 12 14:07:31 2010 NARUSE, Yui <naruse@ruby-lang.org>
|
Tue Jan 12 14:07:31 2010 NARUSE, Yui <naruse@ruby-lang.org>
|
||||||
|
|
||||||
* lib/net/http.rb (Net::HTTP#start): add hash argument to
|
* lib/net/http.rb (Net::HTTP.start): add hash argument to
|
||||||
set ssl related options. when use_ssl is set default value
|
set ssl related options. when use_ssl is set default value
|
||||||
of verify_mode is OpenSSL::SSL::VERIFY_PEER. [ruby-dev:40003]
|
of verify_mode is OpenSSL::SSL::VERIFY_PEER. [ruby-dev:40003]
|
||||||
|
|
||||||
|
|
|
@ -247,7 +247,7 @@ readline_readline(int argc, VALUE *argv, VALUE self)
|
||||||
prompt = RSTRING_PTR(tmp);
|
prompt = RSTRING_PTR(tmp);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!isatty(0) && errno == EBADF) rb_raise(rb_eIOError, "closed stdin");
|
if (!isatty(fileno(rl_instream)) && errno == EBADF) rb_raise(rb_eIOError, "closed stdin");
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
rl_prep_terminal(1);
|
rl_prep_terminal(1);
|
||||||
|
@ -1463,4 +1463,6 @@ Init_readline()
|
||||||
#ifdef HAVE_RL_CLEAR_SIGNALS
|
#ifdef HAVE_RL_CLEAR_SIGNALS
|
||||||
rl_clear_signals();
|
rl_clear_signals();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
readline_s_set_input(mReadline, rb_stdin);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue