more cleanups.

This commit is contained in:
Vítor Santos Costa
2011-03-02 23:19:39 +00:00
parent 6f1537475f
commit da1df3d851
17 changed files with 159 additions and 98 deletions

View File

@@ -220,20 +220,6 @@ pl_rl_read_history(term_t fn)
static int
input_on_fd(int fd)
{ fd_set rfds;
struct timeval tv;
FD_ZERO(&rfds);
FD_SET(fd, &rfds);
tv.tv_sec = 0;
tv.tv_usec = 0;
return select(fd+1, &rfds, NULL, NULL, &tv) != 0;
}
static char *my_prompt = NULL;
static int in_readline = 0;
static int sig_at_level = -1;
@@ -364,6 +350,20 @@ reentrant access is tried.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
#ifdef HAVE_RL_EVENT_HOOK
static int
input_on_fd(int fd)
{ fd_set rfds;
struct timeval tv;
FD_ZERO(&rfds);
FD_SET(fd, &rfds);
tv.tv_sec = 0;
tv.tv_usec = 0;
return select(fd+1, &rfds, NULL, NULL, &tv) != 0;
}
static int
event_hook(void)
{ if ( Sinput->position )