diff options
author | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-05-26 17:39:42 +0000 |
---|---|---|
committer | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-05-26 17:39:42 +0000 |
commit | cd1dc9bdaf0b8f1c84cfacabc4832b4e159d95cd (patch) | |
tree | 2d658b32a52bcdfd483bfd708ef31ed7fc8d3f83 /ext | |
parent | f6adcedb8436216f4aad498ff5a2789c9487646c (diff) | |
download | ruby-cd1dc9bdaf0b8f1c84cfacabc4832b4e159d95cd.tar.gz ruby-cd1dc9bdaf0b8f1c84cfacabc4832b4e159d95cd.tar.xz ruby-cd1dc9bdaf0b8f1c84cfacabc4832b4e159d95cd.zip |
* ext/readline/readline.c (readline_getc): the function for
rl_getc_function must be a byte function.
so use getbyte method. [ruby-dev:38535]
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@23591 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext')
-rw-r--r-- | ext/readline/readline.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ext/readline/readline.c b/ext/readline/readline.c index dee42f006..d86a71415 100644 --- a/ext/readline/readline.c +++ b/ext/readline/readline.c @@ -106,7 +106,7 @@ static char **readline_attempted_completion_function(const char *text, #if defined HAVE_RL_GETC_FUNCTION static VALUE readline_instream; -static ID id_getc; +static ID id_getbyte; static int readline_getc(FILE *); static int @@ -117,7 +117,7 @@ readline_getc(FILE *input) if (!readline_instream) return rl_getc(input); GetOpenFile(readline_instream, ifp); if (rl_instream != ifp->stdio_file) return rl_getc(input); - c = rb_funcall(readline_instream, id_getc, 0, 0); + c = rb_funcall(readline_instream, id_getbyte, 0, 0); if (NIL_P(c)) return EOF; return NUM2CHR(c); } @@ -1372,7 +1372,7 @@ Init_readline() rl_attempted_completion_function = readline_attempted_completion_function; #if defined HAVE_RL_GETC_FUNCTION rl_getc_function = readline_getc; - id_getc = rb_intern_const("getc"); + id_getbyte = rb_intern_const("getbyte"); #elif defined HAVE_RL_EVENT_HOOK rl_event_hook = readline_event; #endif |