/* -*-C-*-
-$Id: osio.h,v 1.17 2003/01/22 02:03:59 cph Exp $
+$Id: osio.h,v 1.18 2003/01/22 18:42:20 cph Exp $
Copyright 1990,1991,1993,1994,1995,1997 Massachusetts Institute of Technology
Copyright 2000,2003 Massachusetts Institute of Technology
typedef PTR select_registry_t;
#define SELECT_MODE_READ 1
#define SELECT_MODE_WRITE 2
+#define SELECT_MODE_ERROR 4
+#define SELECT_MODE_HUP 8
#define SELECT_INTERRUPT (-1)
#define SELECT_PROCESS_STATUS_CHANGE (-2)
/* -*-C-*-
-$Id: prosio.c,v 1.20 2003/01/22 02:04:06 cph Exp $
+$Id: prosio.c,v 1.21 2003/01/22 18:42:26 cph Exp $
Copyright 1987,1990,1991,1992,1993,1994 Massachusetts Institute of Technology
Copyright 1996,1997,2001,2003 Massachusetts Institute of Technology
if (mode > 0)
{
SCHEME_OBJECT sfd = (long_to_integer (fd));
- if ((mode & SELECT_MODE_READ) != 0)
+ if (((mode & SELECT_MODE_READ) != 0)
+ || ((mode & SELECT_MODE_ERROR) != 0)
+ || ((mode & SELECT_MODE_HUP) != 0))
{
VECTOR_SET (vr, ir, sfd);
ir += 1;
/* -*-C-*-
-$Id: uxio.c,v 1.48 2003/01/22 02:04:13 cph Exp $
+$Id: uxio.c,v 1.49 2003/01/22 18:42:32 cph Exp $
Copyright 1990,1991,1992,1993,1994,1995 Massachusetts Institute of Technology
Copyright 1996,1997,1998,2000,2001,2003 Massachusetts Institute of Technology
#define ENCODE_MODE(revents) \
(((((revents) & POLLIN) != 0) ? SELECT_MODE_READ : 0) \
- | ((((revents) & POLLOUT) != 0) ? SELECT_MODE_WRITE : 0))
+ | ((((revents) & POLLOUT) != 0) ? SELECT_MODE_WRITE : 0) \
+ | ((((revents) & POLLERR) != 0) ? SELECT_MODE_ERROR : 0) \
+ | ((((revents) & POLLHUP) != 0) ? SELECT_MODE_HUP : 0))
select_registry_t
DEFUN_VOID (OS_allocate_select_registry)