Added macros for FD_SET and company, if not otherwise defined
authorTheodore Tso <tytso@mit.edu>
Thu, 3 Jun 1993 00:06:48 +0000 (00:06 +0000)
committerTheodore Tso <tytso@mit.edu>
Thu, 3 Jun 1993 00:06:48 +0000 (00:06 +0000)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@2546 dc483132-0cff-0310-8789-dd5450dbe970

src/include/krb5/sysincl.h

index 26ad0d44a922620fb2a397cc0216a922b4ccfa90..7ab845b58cee86d3a34c1dafff55360a2bcdcc3b 100644 (file)
 #define L_XTND          2       /* relative to end of file */
 #endif /* L_SET */
 
+#ifndef FD_SET
+#define FD_SETSIZE          (sizeof (fd_set) * 8)
+
+#define FD_SET(f,s)         ((s)->fds_bits[0] |= (1 << (f)))
+#define FD_CLR(f,s)         ((s)->fds_bits[0] &= ~(1 << (f)))
+#define FD_ISSET(f,s)       ((s)->fds_bits[0] & (1 << (f)))
+#define FD_ZERO(s)          ((s)->fds_bits[0] = 0)
+#endif
+
 #if defined(SYSV) || defined(_AIX)
 #include <fcntl.h>
 #endif