-/* Interface to read_avail_input, blocking SIGIO or SIGALRM if necessary. */
-
-void
-gobble_input (int expected)
-{
-#ifdef USABLE_SIGIO
- if (interrupt_input)
- {
- sigset_t blocked, procmask;
- sigemptyset (&blocked);
- sigaddset (&blocked, SIGIO);
- pthread_sigmask (SIG_BLOCK, &blocked, &procmask);
- read_avail_input (expected);
- pthread_sigmask (SIG_SETMASK, &procmask, 0);
- }
- else
-#ifdef POLL_FOR_INPUT
- /* XXX This condition was (read_socket_hook && !interrupt_input),
- but read_socket_hook is not global anymore. Let's pretend that
- it's always set. */
- if (!interrupt_input && poll_suppress_count == 0)
- {
- sigset_t blocked, procmask;
- sigemptyset (&blocked);
- sigaddset (&blocked, SIGALRM);
- pthread_sigmask (SIG_BLOCK, &blocked, &procmask);
- read_avail_input (expected);
- pthread_sigmask (SIG_SETMASK, &procmask, 0);
- }
- else
-#endif
-#endif
- read_avail_input (expected);
-}
-