ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/common/selcall.h
(Generate patch)

Comparing ray/src/common/selcall.h (file contents):
Revision 3.5 by greg, Tue Feb 25 02:47:22 2003 UTC vs.
Revision 3.9 by schorsch, Mon Jun 30 14:59:11 2003 UTC

# Line 2 | Line 2
2   /*
3   * header file for select call compatibility
4   */
5 + #ifndef _RAD_SELCALL_H_
6 + #define _RAD_SELCALL_H_
7 + #ifdef __cplusplus
8 + extern "C" {
9 + #endif
10  
11 < #include "copyright.h"
7 <
11 > #include <string.h>
12   #include <sys/types.h>
13 < #include <sys/time.h>
13 > #ifdef _WIN32
14 >  /*#include <winsock2.h>*/
15 > #else
16 >  #include <sys/time.h>
17 > #endif
18   #ifdef INCL_SEL_H
19   #include <sys/select.h>
20   #endif
21  
22   #ifndef FD_SETSIZE
23 < #include <sys/param.h>
23 > #ifdef _WIN32
24 > #else
25 >  #include <sys/param.h>
26 > #endif
27   #define FD_SETSIZE      NOFILE          /* maximum # select file descriptors */
28   #endif
29   #ifndef FD_SET
# Line 22 | Line 33
33   #define FD_SET(n, p)    ((p)->fds_bits[(n)/NFDBITS] |= (1 << ((n) % NFDBITS)))
34   #define FD_CLR(n, p)    ((p)->fds_bits[(n)/NFDBITS] &= ~(1 << ((n) % NFDBITS)))
35   #define FD_ISSET(n, p)  ((p)->fds_bits[(n)/NFDBITS] & (1 << ((n) % NFDBITS)))
25 #ifdef BSD
26 #define FD_ZERO(p)      bzero((char *)(p), sizeof(*(p)))
27 #else
36   #define FD_ZERO(p)      memset((char *)(p), 0, sizeof(*(p)))
37   #endif
38 +
39 +
40 + #ifdef __cplusplus
41 + }
42   #endif
43 + #endif /* _RAD_SELCALL_H_ */

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines