}
#ifdef FASYNC /* F_SETFL does not imply existence of FASYNC */
+/* XXX Uhm, FASYNC is not used anymore here. */
++/* XXX Yeah, but you need it for SIGIO, don't you? */
void
request_sigio ()
{
- if (read_socket_hook)
+ /* XXX read_socket_hook is not global anymore. Is blocking SIGIO
+ bad under X? */
+#if 0
+ if (noninteractive || read_socket_hook)
return;
+#endif
#ifdef SIGWINCH
sigunblock (sigmask (SIGWINCH));
}
void
-unrequest_sigio ()
-{
+unrequest_sigio (void)
+{
+ /* XXX read_socket_hook is not global anymore. Is blocking SIGIO
+ bad under X? */
+#if 0
- if (read_socket_hook)
+ if (noninteractive || read_socket_hook)
return;
-
+#endif
+
#ifdef SIGWINCH
sigblock (sigmask (SIGWINCH));
#endif
{
int on = 1;
- if (read_socket_hook)
+ if (noninteractive || read_socket_hook)
return;
- ioctl (input_fd, FIOASYNC, &on);
+ /* XXX CURTTY() is bogus here. */
+ ioctl (fileno (CURTTY ()->input), FIOASYNC, &on);
interrupts_deferred = 0;
}
{
int off = 0;
- if (read_socket_hook)
+ if (noninteractive || read_socket_hook)
return;
- ioctl (input_fd, FIOASYNC, &off);
+ /* XXX CURTTY() is bogus here. */
+ ioctl (fileno (CURTTY ()->input), FIOASYNC, &off);
interrupts_deferred = 1;
}
{
int off = 0;
- if (read_socket_hook)
+ if (noninteractive || read_socket_hook)
return;
- ioctl (input_fd, FIOASYNC, &off);
+ ioctl (0, FIOASYNC, &off); /* XXX This fails for multiple ttys. */
interrupts_deferred = 1;
}