This is the mail archive of the
libc-hacker@sourceware.cygnus.com
mailing list for the glibc project.
Bugfix
- To: libc-hacker@cygnus.com
- Subject: Bugfix
- From: Mark Kettenis <kettenis@phys.uva.nl>
- Date: Mon, 2 Nov 1998 01:08:29 +0100 (CET)
This change parallels the following change:
1998-10-27 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
* sysdeps/generic/bits/types.h (__FDS_BITS): New macro to access
fds_bits member.
and also provides a somewhat cleaner defenition of the __FDMASK macro.
Mark
1998-11-02 Mark Kettenis <kettenis@phys.uva.nl>
* sysdeps/generic/bits/types.h (__FDS_BITS): New macro to access
fds_bits member.
(__FDMASK): Use __fd_mask instead of unsigned long int in cast.
Index: sysdeps/generic/bits/types.h
--- 0.23/sysdeps/generic/bits/types.h Mon, 02 Nov 1998 01:05:49 +0100 kettenis (libc/b/10_types.h 1.1.1.2 644)
+++ Local.17(w)/sysdeps/generic/bits/types.h Mon, 02 Nov 1998 00:58:32 +0100 kettenis (libc/b/10_types.h 1.2 644)
@@ -93,7 +93,7 @@
/* It's easier to assume 8-bit bytes than to get CHAR_BIT. */
#define __NFDBITS (sizeof (unsigned long int) * 8)
#define __FDELT(d) ((d) / __NFDBITS)
-#define __FDMASK(d) ((unsigned long int) 1 << ((d) % __NFDBITS))
+#define __FDMASK(d) ((__fd_mask) 1 << ((d) % __NFDBITS))
/* fd_set for select and pselect. */
typedef struct
@@ -102,8 +102,10 @@
from the user namespace. */
#ifdef __USE_XOPEN
__fd_mask fds_bits[(__FD_SETSIZE + (__NFDBITS - 1)) / __NFDBITS];
+# define __FDS_BITS(set) ((set)->fds_bits)
#else
__fd_mask __fds_bits[(__FD_SETSIZE + (__NFDBITS - 1)) / __NFDBITS];
+# define __FDS_BITS(set) ((set)->__fds_bits)
#endif
} __fd_set;
- Follow-Ups:
- Re: Bugfix
- From: Ulrich Drepper <drepper@cygnus.com>