* ext/readline/readline.c (readline_getc): fix editline compatibility

broken by r36123. [Bug #6601]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36127 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
naruse 2012-06-19 02:58:40 +00:00
Родитель bcc4c40853
Коммит d998ba1c3c
3 изменённых файлов: 8 добавлений и 1 удалений

Просмотреть файл

@ -1,3 +1,8 @@
Tue Jun 19 11:43:16 2012 NARUSE, Yui <naruse@ruby-lang.org>
* ext/readline/readline.c (readline_getc): fix editline compatibility
broken by r36123. [Bug #6601]
Mon Jun 18 17:10:08 2012 Nobuyoshi Nakada <nobu@ruby-lang.org>
* string.c (rb_str_subpos): split from rb_str_substr. returns

Просмотреть файл

@ -174,6 +174,7 @@ readline_getc(FILE *input)
#endif
c = rb_io_getbyte(readline_instream);
if (NIL_P(c)) return EOF;
#ifdef ESC
if (c == INT2FIX(ESC) &&
RL_ISSTATE(RL_STATE_ISEARCH) && /* isn't needed in other states? */
rb_io_read_pending(ifp)) {
@ -184,6 +185,7 @@ readline_getc(FILE *input)
if (meta) rl_execute_next(ESC);
return ESC;
}
#endif
return FIX2INT(c);
}
#elif defined HAVE_RL_EVENT_HOOK

Просмотреть файл

@ -412,7 +412,7 @@ class TestReadline < Test::Unit::TestCase
wo.close
with_pipe {|r, w| w.write("\C-a\C-k\n")} # clear line_buffer
Readline::HISTORY.clear
end
end if !/EditLine/n.match(Readline::VERSION)
private