| 1 | /* utils.h,v 1.6 2004/09/14 22:27:36 bird Exp */ | 
|---|
| 2 | /** @file | 
|---|
| 3 | * OS/2 TCPIP | 
|---|
| 4 | */ | 
|---|
| 5 |  | 
|---|
| 6 | #ifndef _UTILS_H_ | 
|---|
| 7 | #define _UTILS_H_ | 
|---|
| 8 |  | 
|---|
| 9 | #include <sys/cdefs.h> | 
|---|
| 10 |  | 
|---|
| 11 | #ifdef TCPV40HDRS | 
|---|
| 12 |  | 
|---|
| 13 | unsigned long   TCPCALL lswap(unsigned long); | 
|---|
| 14 | unsigned short  TCPCALL bswap(unsigned short); | 
|---|
| 15 | int             TCPCALL rexec(char **, int, char *, char *, char *, int *); | 
|---|
| 16 |  | 
|---|
| 17 | /* Definition for bswap */ | 
|---|
| 18 | #ifndef htonl | 
|---|
| 19 | #include <machine/endian.h> | 
|---|
| 20 | #endif | 
|---|
| 21 |  | 
|---|
| 22 | #define ovbcopy(x,y,z)  bcopy((x),(y),(z)) | 
|---|
| 23 | #define copyout(x,y,z)  memcpy((y),(x),(z)) | 
|---|
| 24 | #ifndef XP_OS2_VACPP /* mozilla */ | 
|---|
| 25 | /* We've got the real thing now. (aliased at least) | 
|---|
| 26 | #define strcasecmp(x,y)     strcmpi((x),(y)) | 
|---|
| 27 | #define strncasecmp(x,y,z)  strnicmp(x,y,z) | 
|---|
| 28 | */ | 
|---|
| 29 | #endif | 
|---|
| 30 |  | 
|---|
| 31 | __BEGIN_DECLS | 
|---|
| 32 |  | 
|---|
| 33 | #if !defined(_SIZE_T_DECLARED) && !defined(_SIZE_T) /* bird: emx */ | 
|---|
| 34 | typedef __size_t        size_t; | 
|---|
| 35 | #define _SIZE_T_DECLARED | 
|---|
| 36 | #define _SIZE_T                         /* bird: emx */ | 
|---|
| 37 | #endif | 
|---|
| 38 |  | 
|---|
| 39 | int strcasecmp (__const__ char *, __const__ char *); | 
|---|
| 40 | int strncasecmp (__const__ char *, __const__ char *, size_t); | 
|---|
| 41 |  | 
|---|
| 42 | __END_DECLS | 
|---|
| 43 |  | 
|---|
| 44 | /* MIN/MAX */ | 
|---|
| 45 | #include <sys/param.h> | 
|---|
| 46 | /* timercmp */ | 
|---|
| 47 | #include <sys/time.h> | 
|---|
| 48 |  | 
|---|
| 49 | #else | 
|---|
| 50 | int     TCPCALL rexec(char **, int, char *, char *, char *, int *); | 
|---|
| 51 | #endif /*TCPV40HDRS*/ | 
|---|
| 52 |  | 
|---|
| 53 | #endif | 
|---|