43 #define GEMD_OUT_OF_MEMORY -1
44 #define EVENT_TIMEDOUT -2
45 #define EVENT_TERMINATE -3
92 #define ERROR_BUFFER_LEN (size_t)256
96 #if !defined(__cplusplus) || defined(UPNP_USE_MSVCPP)
99 #define S_ISREG(m) (((m) & S_IFMT) == S_IFREG)
102 #define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
105 #define EADDRINUSE WSAEADDRINUSE
107 #define strcasecmp stricmp
108 #define strncasecmp strnicmp
109 #define sleep(a) Sleep((a)*1000)
110 #define usleep(a) Sleep((a)/1000)
111 #define strerror_r(a,b,c) (strerror_s((b),(c),(a)))
113 #define max(a, b) (((a)>(b))? (a):(b))
114 #define min(a, b) (((a)<(b))? (a):(b))
void linecopylen(char dest[LINE_SIZE], const char *src, size_t srclen)
Determine if the srclen passed in paramter is less than the permitted LINE_SIZE. If it is use the pas...
Definition: util.c:60
void namecopy(char dest[NAME_SIZE], const char *src)
Copy no of bytes spcified by the NAME_SIZE constant, from the source buffer. Null terminate the desti...
Definition: util.c:53
void linecopy(char dest[LINE_SIZE], const char *src)
Copy no of bytes spcified by the LINE_SIZE constant, from the source buffer. Null terminate the desti...
Definition: util.c:46