-/* config.h.in. Generated automatically from configure.in by autoheader. */
-/* Define if kqueue works correctly with pipes */
-#undef HAVE_WORKING_KQUEUE
+/* config.h. Generated by configure. */
+/* config.h.in. Generated from configure.in by autoheader. */
-/* Define to `unsigned long long' if <sys/types.h> doesn't define. */
-#undef u_int64_t
+/* Define if clock_gettime is available in libc */
+/* #undef DNS_USE_CPU_CLOCK_FOR_ID */
-/* Define to `unsigned int' if <sys/types.h> doesn't define. */
-#undef u_int32_t
+/* Define if no secure id variant is available */
+#define DNS_USE_FTIME_FOR_ID 1
-/* Define to `unsigned short' if <sys/types.h> doesn't define. */
-#undef u_int16_t
+/* Define if no secure id variant is available */
+/* #define DNS_USE_GETTIMEOFDAY_FOR_ID 1 */
-/* Define to `unsigned char' if <sys/types.h> doesn't define. */
-#undef u_int8_t
+/* Define to 1 if you have the `clock_gettime' function. */
+/* #undef HAVE_CLOCK_GETTIME */
-/* Define if timeradd is defined in <sys/time.h> */
-#undef HAVE_TIMERADD
-#ifndef HAVE_TIMERADD
-#undef timersub
-#define timeradd(tvp, uvp, vvp) \
- do { \
- (vvp)->tv_sec = (tvp)->tv_sec + (uvp)->tv_sec; \
- (vvp)->tv_usec = (tvp)->tv_usec + (uvp)->tv_usec; \
- if ((vvp)->tv_usec >= 1000000) { \
- (vvp)->tv_sec++; \
- (vvp)->tv_usec -= 1000000; \
- } \
- } while (0)
-#define timersub(tvp, uvp, vvp) \
- do { \
- (vvp)->tv_sec = (tvp)->tv_sec - (uvp)->tv_sec; \
- (vvp)->tv_usec = (tvp)->tv_usec - (uvp)->tv_usec; \
- if ((vvp)->tv_usec < 0) { \
- (vvp)->tv_sec--; \
- (vvp)->tv_usec += 1000000; \
- } \
- } while (0)
-#endif /* !HAVE_TIMERADD */
-
-#undef HAVE_TIMERCLEAR
-#ifndef HAVE_TIMERCLEAR
-#define timerclear(tvp) (tvp)->tv_sec = (tvp)->tv_usec = 0
-#endif
+/* Define if /dev/poll is available */
+/* #undef HAVE_DEVPOLL */
-#define HAVE_TIMERCMP
-#ifndef HAVE_TIMERCMP
-#undef timercmp
-#define timercmp(tvp, uvp, cmp) \
- (((tvp)->tv_sec == (uvp)->tv_sec) ? \
- ((tvp)->tv_usec cmp (uvp)->tv_usec) : \
- ((tvp)->tv_sec cmp (uvp)->tv_sec))
-#endif
+/* Define to 1 if you have the <dlfcn.h> header file. */
+/* #undef HAVE_DLFCN_H */
-#undef HAVE_TIMERISSET
-#ifndef HAVE_TIMERISSET
-#undef timerisset
-#define timerisset(tvp) ((tvp)->tv_sec || (tvp)->tv_usec)
-#endif
+/* Define if your system supports the epoll system calls */
+/* #undef HAVE_EPOLL */
-/* Define if TAILQ_FOREACH is defined in <sys/queue.h> */
-#define HAVE_TAILQFOREACH
-#ifndef HAVE_TAILQFOREACH
-#define TAILQ_FIRST(head) ((head)->tqh_first)
-#define TAILQ_END(head) NULL
-#define TAILQ_NEXT(elm, field) ((elm)->field.tqe_next)
-#define TAILQ_FOREACH(var, head, field) \
- for((var) = TAILQ_FIRST(head); \
- (var) != TAILQ_END(head); \
- (var) = TAILQ_NEXT(var, field))
-#define TAILQ_INSERT_BEFORE(listelm, elm, field) do { \
- (elm)->field.tqe_prev = (listelm)->field.tqe_prev; \
- (elm)->field.tqe_next = (listelm); \
- *(listelm)->field.tqe_prev = (elm); \
- (listelm)->field.tqe_prev = &(elm)->field.tqe_next; \
-} while (0)
-#endif /* TAILQ_FOREACH */
+/* Define to 1 if you have the `epoll_ctl' function. */
+/* #undef HAVE_EPOLL_CTL */
-/* Define if /dev/poll is available */
-#undef HAVE_DEVPOLL
+/* Define if your system supports event ports */
+/* #undef HAVE_EVENT_PORTS */
-/* Define if your system supports the epoll system calls */
-#undef HAVE_EPOLL
+/* Define to 1 if you have the `fcntl' function. */
+/* #undef HAVE_FCNTL */
-/* Define if you have the `epoll_ctl' function. */
-#undef HAVE_EPOLL_CTL
+/* Define to 1 if you have the <fcntl.h> header file. */
+#define HAVE_FCNTL_H 1
-/* Define if you have the `err' function. */
-#undef HAVE_ERR
+/* Define to 1 if you have the `getaddrinfo' function. */
+/* #undef HAVE_GETADDRINFO */
-/* Define if you have the `fcntl' function. */
-#undef HAVE_FCNTL
+/* Define to 1 if you have the `getnameinfo' function. */
+/* #undef HAVE_GETNAMEINFO */
-/* Define if you have the <fcntl.h> header file. */
-#undef HAVE_FCNTL_H
+/* Define to 1 if you have the `gettimeofday' function. */
+/* #define HAVE_GETTIMEOFDAY 1 */
-/* Define if you have the `gettimeofday' function. */
-#define HAVE_GETTIMEOFDAY 1
+/* Define to 1 if you have the `inet_ntop' function. */
+/* #undef HAVE_INET_NTOP */
-/* Define if you have the <inttypes.h> header file. */
+/* Define to 1 if you have the <inttypes.h> header file. */
#define HAVE_INTTYPES_H 1
-/* Define if you have the `kqueue' function. */
-#undef HAVE_KQUEUE
+/* Define to 1 if you have the `kqueue' function. */
+/* #undef HAVE_KQUEUE */
+
+/* Define to 1 if you have the `nsl' library (-lnsl). */
+/* #undef HAVE_LIBNSL */
+
+/* Define to 1 if you have the `resolv' library (-lresolv). */
+/* #undef HAVE_LIBRESOLV */
-/* Define if you have the `socket' library (-lsocket). */
-#undef HAVE_LIBSOCKET
+/* Define to 1 if you have the `rt' library (-lrt). */
+/* #undef HAVE_LIBRT */
-/* Define if you have the <memory.h> header file. */
+/* Define to 1 if you have the `socket' library (-lsocket). */
+/* #undef HAVE_LIBSOCKET */
+
+/* Define to 1 if you have the <memory.h> header file. */
#define HAVE_MEMORY_H 1
-/* Define if you have the `poll' function. */
-#undef HAVE_POLL
+/* Define to 1 if you have the <netinet/in6.h> header file. */
+/* #undef HAVE_NETINET_IN6_H */
+
+/* Define to 1 if you have the `poll' function. */
+/* #undef HAVE_POLL */
-/* Define if you have the <poll.h> header file. */
-#undef HAVE_POLL_H
+/* Define to 1 if you have the <poll.h> header file. */
+/* #undef HAVE_POLL_H */
-/* Define if your system supports POSIX realtime signals */
-#undef HAVE_RTSIG
+/* Define to 1 if you have the `port_create' function. */
+/* #undef HAVE_PORT_CREATE */
-/* Define if you have the `select' function. */
-#undef HAVE_SELECT
+/* Define to 1 if you have the <port.h> header file. */
+/* #undef HAVE_PORT_H */
+
+/* Define to 1 if you have the `select' function. */
+/* #undef HAVE_SELECT */
/* Define if F_SETFD is defined in <fcntl.h> */
-#undef HAVE_SETFD
+/* #undef HAVE_SETFD */
+
+/* Define to 1 if you have the `sigaction' function. */
+/* #undef HAVE_SIGACTION */
-/* Define if you have the <signal.h> header file. */
-#undef HAVE_SIGNAL_H
+/* Define to 1 if you have the `signal' function. */
+#define HAVE_SIGNAL 1
-/* Define if you have the `sigtimedwait' function. */
-#undef HAVE_SIGTIMEDWAIT
+/* Define to 1 if you have the <signal.h> header file. */
+#define HAVE_SIGNAL_H 1
-/* Define if you have the <stdarg.h> header file. */
+/* Define to 1 if you have the <stdarg.h> header file. */
#define HAVE_STDARG_H 1
-/* Define if you have the <stdint.h> header file. */
-#undef HAVE_STDINT_H
+/* Define to 1 if you have the <stdint.h> header file. */
+/* #define HAVE_STDINT_H 1 */
-/* Define if you have the <stdlib.h> header file. */
+/* Define to 1 if you have the <stdlib.h> header file. */
#define HAVE_STDLIB_H 1
-/* Define if you have the <strings.h> header file. */
-#undef HAVE_STRINGS_H
+/* Define to 1 if you have the <strings.h> header file. */
+#define HAVE_STRINGS_H 1
-/* Define if you have the <string.h> header file. */
+/* Define to 1 if you have the <string.h> header file. */
#define HAVE_STRING_H 1
-/* Define if you have the <sys/devpoll.h> header file. */
-#undef HAVE_SYS_DEVPOLL_H
+/* Define to 1 if you have the `strlcpy' function. */
+/* #undef HAVE_STRLCPY */
+
+/* Define to 1 if you have the `strsep' function. */
+/* #undef HAVE_STRSEP */
+
+/* Define to 1 if you have the `strtok_r' function. */
+/* #undef HAVE_STRTOK_R */
-/* Define if you have the <sys/epoll.h> header file. */
-#undef HAVE_SYS_EPOLL_H
+/* Define to 1 if the system has the type `struct in6_addr'. */
+#define HAVE_STRUCT_IN6_ADDR 1
-/* Define if you have the <sys/event.h> header file. */
-#undef HAVE_SYS_EVENT_H
+/* Define to 1 if you have the <sys/devpoll.h> header file. */
+/* #undef HAVE_SYS_DEVPOLL_H */
-/* Define if you have the <sys/ioctl.h> header file. */
-#undef HAVE_SYS_IOCTL_H
+/* Define to 1 if you have the <sys/epoll.h> header file. */
+/* #undef HAVE_SYS_EPOLL_H */
-/* Define if you have the <sys/queue.h> header file. */
-#undef HAVE_SYS_QUEUE_H
+/* Define to 1 if you have the <sys/event.h> header file. */
+/* #undef HAVE_SYS_EVENT_H */
-/* Define if you have the <sys/stat.h> header file. */
-#define HAVE_SYS_STAT_H 1
+/* Define to 1 if you have the <sys/ioctl.h> header file. */
+/* #undef HAVE_SYS_IOCTL_H */
-/* Define if you have the <sys/time.h> header file. */
-#undef HAVE_SYS_TIME_H
+/* Define to 1 if you have the <sys/queue.h> header file. */
+/* #undef HAVE_SYS_QUEUE_H */
-/* Define if you have the <sys/types.h> header file. */
-#define HAVE_SYS_TYPES_H 1
+/* Define to 1 if you have the <sys/select.h> header file. */
+/* #undef HAVE_SYS_SELECT_H */
+
+/* Define to 1 if you have the <sys/socket.h> header file. */
+/* #undef HAVE_SYS_SOCKET_H */
+
+/* Define to 1 if you have the <sys/stat.h> header file. */
+/* #define HAVE_SYS_STAT_H 1 */
+
+/* Define to 1 if you have the <sys/time.h> header file. */
+/* #define HAVE_SYS_TIME_H 1 */
+
+/* Define to 1 if you have the <sys/types.h> header file. */
+/* #define HAVE_SYS_TYPES_H 1 */
/* Define if TAILQ_FOREACH is defined in <sys/queue.h> */
-#undef HAVE_TAILQFOREACH
+/* #undef HAVE_TAILQFOREACH */
/* Define if timeradd is defined in <sys/time.h> */
-#undef HAVE_TIMERADD
+/* #undef HAVE_TIMERADD */
-/* Define if you have the <unistd.h> header file. */
-#undef HAVE_UNISTD_H
+/* Define if timerclear is defined in <sys/time.h> */
+/* #define HAVE_TIMERCLEAR 1 */
-/* Define if you have the `vasprintf' function. */
-#undef HAVE_VASPRINTF
+/* Define if timercmp is defined in <sys/time.h> */
+#define HAVE_TIMERCMP 1
-/* Define if kqueue works correctly with pipes */
-#undef HAVE_WORKING_KQUEUE
+/* Define if timerisset is defined in <sys/time.h> */
+#define HAVE_TIMERISSET 1
-/* Define if realtime signals work on pipes */
-#undef HAVE_WORKING_RTSIG
+/* Define to 1 if you have the <unistd.h> header file. */
+/* #define HAVE_UNISTD_H 1 */
+
+/* Define to 1 if you have the `vasprintf' function. */
+/* #undef HAVE_VASPRINTF */
+
+/* Define if kqueue works correctly with pipes */
+/* #undef HAVE_WORKING_KQUEUE */
/* Name of package */
#define PACKAGE "libevent"
-/* Define if you have the ANSI C header files. */
-#undef STDC_HEADERS
+/* Define to the address where bug reports for this package should be sent. */
+#define PACKAGE_BUGREPORT ""
+
+/* Define to the full name of this package. */
+#define PACKAGE_NAME ""
-/* Define if you can safely include both <sys/time.h> and <time.h>. */
-#undef TIME_WITH_SYS_TIME
+/* Define to the full name and version of this package. */
+#define PACKAGE_STRING ""
+
+/* Define to the one symbol short name of this package. */
+#define PACKAGE_TARNAME ""
+
+/* Define to the version of this package. */
+#define PACKAGE_VERSION ""
+
+/* Define to 1 if you have the ANSI C header files. */
+#define STDC_HEADERS 1
+
+/* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
+#define TIME_WITH_SYS_TIME 1
/* Version number of package */
-#define VERSION "1.0b"
+#define VERSION "1.3.99-trunk"
+
+/* Define to appropriate substitue if compiler doesnt have __func__ */
+#define __func__ __FUNCTION__
/* Define to empty if `const' does not conform to ANSI C. */
-#undef const
+/* #undef const */
-/* Define as `__inline' if that's what the C compiler calls it, or to nothing
- if it is not supported. */
+/* Define to `__inline__' or `__inline' if that's what the C compiler
+ calls it, or to nothing if 'inline' is not supported under any name. */
+#ifndef __cplusplus
#define inline __inline
+#endif
/* Define to `int' if <sys/types.h> does not define. */
-#undef pid_t
+/* #undef pid_t */
/* Define to `unsigned' if <sys/types.h> does not define. */
-#undef size_t
+/* #undef size_t */
/* Define to unsigned int if you dont have it */
-#undef socklen_t
+#define socklen_t unsigned int
/* Define to `unsigned short' if <sys/types.h> does not define. */
-#undef u_int16_t
+#define uint16_t unsigned short
/* Define to `unsigned int' if <sys/types.h> does not define. */
-#undef u_int32_t
+#define uint32_t unsigned int
/* Define to `unsigned long long' if <sys/types.h> does not define. */
-/* #undef u_int64_t */
+#define uint64_t __uint64_t
/* Define to `unsigned char' if <sys/types.h> does not define. */
-/* #undef u_int8_t */
-
-/* Define to __FUNCTION__ or __file__ if your compiler doesn't have __func__ */
-#define __func__ __FUNCTION__
+#define uint8_t unsigned char
--- /dev/null
+/* event-config.h
+ * Generated by autoconf; post-processed by libevent.
+ * Do not edit this file.
+ * Do not rely on macros in this file existing in later versions.
+ */
+#ifndef _EVENT_CONFIG_H_
+#define _EVENT_CONFIG_H_
+/* config.h. Generated by configure. */
+/* config.h.in. Generated from configure.in by autoheader. */
+
+/* Define if clock_gettime is available in libc */
+/* #undef _EVENT_DNS_USE_CPU_CLOCK_FOR_ID */
+
+/* Define is no secure id variant is available */
+#define _EVENT_DNS_USE_GETTIMEOFDAY_FOR_ID 1
+
+/* Define to 1 if you have the `clock_gettime' function. */
+/* #undef _EVENT_HAVE_CLOCK_GETTIME */
+
+/* Define if /dev/poll is available */
+/* #undef _EVENT_HAVE_DEVPOLL */
+
+/* Define to 1 if you have the <dlfcn.h> header file. */
+/* #undef _EVENT_HAVE_DLFCN_H */
+
+/* Define if your system supports the epoll system calls */
+/* #undef _EVENT_HAVE_EPOLL */
+
+/* Define to 1 if you have the `epoll_ctl' function. */
+/* #undef _EVENT_HAVE_EPOLL_CTL */
+
+/* Define if your system supports event ports */
+/* #undef _EVENT_HAVE_EVENT_PORTS */
+
+/* Define to 1 if you have the `fcntl' function. */
+/* #undef _EVENT_HAVE_FCNTL */
+
+/* Define to 1 if you have the <fcntl.h> header file. */
+#define _EVENT_HAVE_FCNTL_H 1
+
+/* Define to 1 if you have the `getaddrinfo' function. */
+/* #undef _EVENT_HAVE_GETADDRINFO */
+
+/* Define to 1 if you have the `getnameinfo' function. */
+/* #undef _EVENT_HAVE_GETNAMEINFO */
+
+/* Define to 1 if you have the `gettimeofday' function. */
+/* #define _EVENT_HAVE_GETTIMEOFDAY 1 */
+
+/* Define to 1 if you have the `inet_ntop' function. */
+/* #undef _EVENT_HAVE_INET_NTOP */
+
+/* Define to 1 if you have the <inttypes.h> header file. */
+#define _EVENT_HAVE_INTTYPES_H 1
+
+/* Define to 1 if you have the `kqueue' function. */
+/* #undef _EVENT_HAVE_KQUEUE */
+
+/* Define to 1 if you have the `nsl' library (-lnsl). */
+/* #undef _EVENT_HAVE_LIBNSL */
+
+/* Define to 1 if you have the `resolv' library (-lresolv). */
+/* #undef _EVENT_HAVE_LIBRESOLV */
+
+/* Define to 1 if you have the `rt' library (-lrt). */
+/* #undef _EVENT_HAVE_LIBRT */
+
+/* Define to 1 if you have the `socket' library (-lsocket). */
+/* #undef _EVENT_HAVE_LIBSOCKET */
+
+/* Define to 1 if you have the <memory.h> header file. */
+#define _EVENT_HAVE_MEMORY_H 1
+
+/* Define to 1 if you have the <netinet/in6.h> header file. */
+/* #undef _EVENT_HAVE_NETINET_IN6_H */
+
+/* Define to 1 if you have the `poll' function. */
+/* #undef _EVENT_HAVE_POLL */
+
+/* Define to 1 if you have the <poll.h> header file. */
+/* #undef _EVENT_HAVE_POLL_H */
+
+/* Define to 1 if you have the `port_create' function. */
+/* #undef _EVENT_HAVE_PORT_CREATE */
+
+/* Define to 1 if you have the <port.h> header file. */
+/* #undef _EVENT_HAVE_PORT_H */
+
+/* Define to 1 if you have the `select' function. */
+/* #undef _EVENT_HAVE_SELECT */
+
+/* Define if F_SETFD is defined in <fcntl.h> */
+/* #undef _EVENT_HAVE_SETFD */
+
+/* Define to 1 if you have the `sigaction' function. */
+/* #undef _EVENT_HAVE_SIGACTION */
+
+/* Define to 1 if you have the `signal' function. */
+#define _EVENT_HAVE_SIGNAL 1
+
+/* Define to 1 if you have the <signal.h> header file. */
+#define _EVENT_HAVE_SIGNAL_H 1
+
+/* Define to 1 if you have the <stdarg.h> header file. */
+#define _EVENT_HAVE_STDARG_H 1
+
+/* Define to 1 if you have the <stdint.h> header file. */
+/* #define _EVENT_HAVE_STDINT_H 1 */
+
+/* Define to 1 if you have the <stdlib.h> header file. */
+#define _EVENT_HAVE_STDLIB_H 1
+
+/* Define to 1 if you have the <strings.h> header file. */
+#define _EVENT_HAVE_STRINGS_H 1
+
+/* Define to 1 if you have the <string.h> header file. */
+#define _EVENT_HAVE_STRING_H 1
+
+/* Define to 1 if you have the `strlcpy' function. */
+/* #undef _EVENT_HAVE_STRLCPY */
+
+/* Define to 1 if you have the `strsep' function. */
+/* #undef _EVENT_HAVE_STRSEP */
+
+/* Define to 1 if you have the `strtok_r' function. */
+/* #undef _EVENT_HAVE_STRTOK_R */
+
+/* Define to 1 if the system has the type `struct in6_addr'. */
+#define _EVENT_HAVE_STRUCT_IN6_ADDR 1
+
+/* Define to 1 if you have the <sys/devpoll.h> header file. */
+/* #undef _EVENT_HAVE_SYS_DEVPOLL_H */
+
+/* Define to 1 if you have the <sys/epoll.h> header file. */
+/* #undef _EVENT_HAVE_SYS_EPOLL_H */
+
+/* Define to 1 if you have the <sys/event.h> header file. */
+/* #undef _EVENT_HAVE_SYS_EVENT_H */
+
+/* Define to 1 if you have the <sys/ioctl.h> header file. */
+/* #undef _EVENT_HAVE_SYS_IOCTL_H */
+
+/* Define to 1 if you have the <sys/queue.h> header file. */
+/* #undef _EVENT_HAVE_SYS_QUEUE_H */
+
+/* Define to 1 if you have the <sys/select.h> header file. */
+/* #undef _EVENT_HAVE_SYS_SELECT_H */
+
+/* Define to 1 if you have the <sys/socket.h> header file. */
+/* #undef _EVENT_HAVE_SYS_SOCKET_H */
+
+/* Define to 1 if you have the <sys/stat.h> header file. */
+#define _EVENT_HAVE_SYS_STAT_H 1
+
+/* Define to 1 if you have the <sys/time.h> header file. */
+/* #define _EVENT_HAVE_SYS_TIME_H 1 */
+
+/* Define to 1 if you have the <sys/types.h> header file. */
+/* #define _EVENT_HAVE_SYS_TYPES_H 1 */
+
+/* Define if TAILQ_FOREACH is defined in <sys/queue.h> */
+/* #undef _EVENT_HAVE_TAILQFOREACH */
+
+/* Define if timeradd is defined in <sys/time.h> */
+/* #undef _EVENT_HAVE_TIMERADD */
+
+/* Define if timerclear is defined in <sys/time.h> */
+/* #define _EVENT_HAVE_TIMERCLEAR 1 */
+
+/* Define if timercmp is defined in <sys/time.h> */
+#define _EVENT_HAVE_TIMERCMP 1
+
+/* Define if timerisset is defined in <sys/time.h> */
+#define _EVENT_HAVE_TIMERISSET 1
+
+/* Define to 1 if you have the <unistd.h> header file. */
+/* #define _EVENT_HAVE_UNISTD_H 1 */
+
+/* Define to 1 if you have the `vasprintf' function. */
+/* #undef _EVENT_HAVE_VASPRINTF */
+
+/* Define if kqueue works correctly with pipes */
+/* #undef _EVENT_HAVE_WORKING_KQUEUE */
+
+/* Name of package */
+#define _EVENT_PACKAGE "libevent"
+
+/* Define to the address where bug reports for this package should be sent. */
+#define _EVENT_PACKAGE_BUGREPORT ""
+
+/* Define to the full name of this package. */
+#define _EVENT_PACKAGE_NAME ""
+
+/* Define to the full name and version of this package. */
+#define _EVENT_PACKAGE_STRING ""
+
+/* Define to the one symbol short name of this package. */
+#define _EVENT_PACKAGE_TARNAME ""
+
+/* Define to the version of this package. */
+#define _EVENT_PACKAGE_VERSION ""
+
+/* Define to 1 if you have the ANSI C header files. */
+#define _EVENT_STDC_HEADERS 1
+
+/* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
+#define _EVENT_TIME_WITH_SYS_TIME 1
+
+/* Version number of package */
+#define _EVENT_VERSION "1.3.99-trunk"
+
+/* Define to appropriate substitue if compiler doesnt have __func__ */
+/* #undef _EVENT___func__ */
+
+/* Define to empty if `const' does not conform to ANSI C. */
+/* #undef _EVENT_const */
+
+/* Define to `__inline__' or `__inline' if that's what the C compiler
+ calls it, or to nothing if 'inline' is not supported under any name. */
+#ifndef _EVENT___cplusplus
+#define _EVENT_inline __inline
+#endif
+
+/* Define to `int' if <sys/types.h> does not define. */
+/* #undef _EVENT_pid_t */
+
+/* Define to `unsigned' if <sys/types.h> does not define. */
+/* #undef _EVENT_size_t */
+
+/* Define to unsigned int if you dont have it */
+#define _EVENT_socklen_t unsigned int
+
+/* Define to `unsigned short' if <sys/types.h> does not define. */
+/* #undef _EVENT_uint16_t */
+
+/* Define to `unsigned int' if <sys/types.h> does not define. */
+/* #undef _EVENT_uint32_t */
+
+/* Define to `unsigned long long' if <sys/types.h> does not define. */
+/* #undef _EVENT_uint64_t */
+
+/* Define to `unsigned char' if <sys/types.h> does not define. */
+/* #undef _EVENT_uint8_t */
+#endif
#ifndef HAVE_GETTIMEOFDAY
int gettimeofday(struct timeval *tv, struct timezone *tz) {
- struct _timeb tb;
+ struct _timeb tb;
if(tv == NULL)
return -1;
_ftime(&tb);
- tv->tv_sec = tb.time;
+ tv->tv_sec = (long) tb.time;
tv->tv_usec = ((int) tb.millitm) * 1000;
return 0;
}
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifdef _MSC_VER
-#include "config.h"
+#include "./config.h"
#else
/* Avoid the windows/msvc thing. */
#include "../config.h"
#endif
-#include <windows.h>
#include <winsock2.h>
+#include <windows.h>
#include <sys/types.h>
#include <sys/queue.h>
#include <signal.h>
--- /dev/null
+<?xml version="1.0" encoding="Windows-1252"?>\r
+<VisualStudioProject\r
+ ProjectType="Visual C++"\r
+ Version="8.00"\r
+ Name="libevent"\r
+ ProjectGUID="{B98ABFCE-24D4-4B70-94DE-EF7F1E0662F9}"\r
+ >\r
+ <Platforms>\r
+ <Platform\r
+ Name="Win32"\r
+ />\r
+ </Platforms>\r
+ <ToolFiles>\r
+ </ToolFiles>\r
+ <Configurations>\r
+ <Configuration\r
+ Name="Debug|Win32"\r
+ OutputDirectory=".\Debug"\r
+ IntermediateDirectory=".\Debug"\r
+ ConfigurationType="4"\r
+ InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
+ UseOfMFC="0"\r
+ ATLMinimizesCRunTimeLibraryUsage="false"\r
+ CharacterSet="2"\r
+ >\r
+ <Tool\r
+ Name="VCPreBuildEventTool"\r
+ />\r
+ <Tool\r
+ Name="VCCustomBuildTool"\r
+ />\r
+ <Tool\r
+ Name="VCXMLDataGeneratorTool"\r
+ />\r
+ <Tool\r
+ Name="VCWebServiceProxyGeneratorTool"\r
+ />\r
+ <Tool\r
+ Name="VCMIDLTool"\r
+ />\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ Optimization="0"\r
+ AdditionalIncludeDirectories="..\,..\WIN32-Code,..\compat"\r
+ PreprocessorDefinitions="WIN32,HAVE_CONFIG_H,_CRT_SECURE_NO_DEPRECATE"\r
+ MinimalRebuild="true"\r
+ BasicRuntimeChecks="3"\r
+ RuntimeLibrary="1"\r
+ PrecompiledHeaderFile=".\Debug/libevent.pch"\r
+ AssemblerListingLocation=".\Debug/"\r
+ ObjectFile=".\Debug/"\r
+ ProgramDataBaseFileName=".\Debug/"\r
+ WarningLevel="3"\r
+ SuppressStartupBanner="true"\r
+ DebugInformationFormat="4"\r
+ CompileAs="1"\r
+ />\r
+ <Tool\r
+ Name="VCManagedResourceCompilerTool"\r
+ />\r
+ <Tool\r
+ Name="VCResourceCompilerTool"\r
+ PreprocessorDefinitions="_DEBUG"\r
+ Culture="1033"\r
+ />\r
+ <Tool\r
+ Name="VCPreLinkEventTool"\r
+ />\r
+ <Tool\r
+ Name="VCLibrarianTool"\r
+ OutputFile=".\Debug\libevent.lib"\r
+ SuppressStartupBanner="true"\r
+ />\r
+ <Tool\r
+ Name="VCALinkTool"\r
+ />\r
+ <Tool\r
+ Name="VCXDCMakeTool"\r
+ />\r
+ <Tool\r
+ Name="VCBscMakeTool"\r
+ SuppressStartupBanner="true"\r
+ OutputFile=".\Debug/libevent.bsc"\r
+ />\r
+ <Tool\r
+ Name="VCFxCopTool"\r
+ />\r
+ <Tool\r
+ Name="VCPostBuildEventTool"\r
+ />\r
+ </Configuration>\r
+ <Configuration\r
+ Name="Release|Win32"\r
+ OutputDirectory=".\Release"\r
+ IntermediateDirectory=".\Release"\r
+ ConfigurationType="4"\r
+ InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
+ UseOfMFC="0"\r
+ ATLMinimizesCRunTimeLibraryUsage="false"\r
+ CharacterSet="2"\r
+ >\r
+ <Tool\r
+ Name="VCPreBuildEventTool"\r
+ />\r
+ <Tool\r
+ Name="VCCustomBuildTool"\r
+ />\r
+ <Tool\r
+ Name="VCXMLDataGeneratorTool"\r
+ />\r
+ <Tool\r
+ Name="VCWebServiceProxyGeneratorTool"\r
+ />\r
+ <Tool\r
+ Name="VCMIDLTool"\r
+ />\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ Optimization="2"\r
+ InlineFunctionExpansion="1"\r
+ AdditionalIncludeDirectories="..\,..\WIN32-Code,..\compat"\r
+ PreprocessorDefinitions="WIN32,HAVE_CONFIG_H,_CRT_SECURE_NO_DEPRECATE"\r
+ StringPooling="true"\r
+ RuntimeLibrary="0"\r
+ EnableFunctionLevelLinking="true"\r
+ PrecompiledHeaderFile=".\Release/libevent.pch"\r
+ AssemblerListingLocation=".\Release/"\r
+ ObjectFile=".\Release/"\r
+ ProgramDataBaseFileName=".\Release/"\r
+ WarningLevel="3"\r
+ SuppressStartupBanner="true"\r
+ CompileAs="1"\r
+ />\r
+ <Tool\r
+ Name="VCManagedResourceCompilerTool"\r
+ />\r
+ <Tool\r
+ Name="VCResourceCompilerTool"\r
+ PreprocessorDefinitions="NDEBUG"\r
+ Culture="1033"\r
+ />\r
+ <Tool\r
+ Name="VCPreLinkEventTool"\r
+ />\r
+ <Tool\r
+ Name="VCLibrarianTool"\r
+ OutputFile=".\Release\libevent.lib"\r
+ SuppressStartupBanner="true"\r
+ />\r
+ <Tool\r
+ Name="VCALinkTool"\r
+ />\r
+ <Tool\r
+ Name="VCXDCMakeTool"\r
+ />\r
+ <Tool\r
+ Name="VCBscMakeTool"\r
+ SuppressStartupBanner="true"\r
+ OutputFile=".\Release/libevent.bsc"\r
+ />\r
+ <Tool\r
+ Name="VCFxCopTool"\r
+ />\r
+ <Tool\r
+ Name="VCPostBuildEventTool"\r
+ />\r
+ </Configuration>\r
+ </Configurations>\r
+ <References>\r
+ </References>\r
+ <Files>\r
+ <Filter\r
+ Name="Source Files"\r
+ Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"\r
+ >\r
+ <File\r
+ RelativePath="..\buffer.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\evbuffer.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\evdns.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\event.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ AdditionalIncludeDirectories=""\r
+ PreprocessorDefinitions=""\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ AdditionalIncludeDirectories=""\r
+ PreprocessorDefinitions=""\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\event_tagging.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\evrpc.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\evutil.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\http.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\log.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ AdditionalIncludeDirectories=""\r
+ PreprocessorDefinitions=""\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ AdditionalIncludeDirectories=""\r
+ PreprocessorDefinitions=""\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\WIN32-Code\misc.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ AdditionalIncludeDirectories=""\r
+ PreprocessorDefinitions=""\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ AdditionalIncludeDirectories=""\r
+ PreprocessorDefinitions=""\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\signal.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\strlcpy.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\WIN32-Code\win32.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ AdditionalIncludeDirectories=""\r
+ PreprocessorDefinitions=""\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ AdditionalIncludeDirectories=""\r
+ PreprocessorDefinitions=""\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ </Filter>\r
+ <Filter\r
+ Name="Header Files"\r
+ Filter="h;hpp;hxx;hm;inl"\r
+ >\r
+ <File\r
+ RelativePath="..\WIN32-Code\config.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\evdns.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\WIN32-Code\event-config.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\event-internal.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\event.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\evhttp.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\evrpc-internal.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\evrpc.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\evsignal.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\evutil.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\http-internal.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\min_heap.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\WIN32-Code\misc.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\strlcpy-internal.h"\r
+ >\r
+ </File>\r
+ </Filter>\r
+ </Files>\r
+ <Globals>\r
+ </Globals>\r
+</VisualStudioProject>\r
#endif
#ifdef WIN32
-#include <windows.h>
#include <winsock2.h>
+#include <windows.h>
#endif
#ifdef HAVE_VASPRINTF
#endif
#include "event.h"
+#include "config.h"
struct evbuffer *
evbuffer_new(void)
dnl Checks for header files.
AC_HEADER_STDC
-AC_CHECK_HEADERS(fcntl.h stdarg.h inttypes.h stdint.h poll.h signal.h unistd.h sys/epoll.h sys/time.h sys/queue.h sys/event.h sys/ioctl.h sys/select.h sys/devpoll.h port.h netinet/in6.h sys/socket.h)
+AC_CHECK_HEADERS(fcntl.h stdarg.h inttypes.h stdint.h poll.h signal.h unistd.h sys/epoll.h sys/time.h sys/queue.h sys/event.h sys/param.h sys/ioctl.h sys/select.h sys/devpoll.h port.h netinet/in6.h sys/socket.h)
if test "x$ac_cv_header_sys_queue_h" = "xyes"; then
AC_MSG_CHECKING(for TAILQ_FOREACH in sys/queue.h)
AC_EGREP_CPP(yes,
#include <stdarg.h>
#endif
+#ifdef WIN32
+#include <winsock2.h>
+#endif
+
#include "evutil.h"
#include "event.h"
#include "misc.h"
#endif
+#ifdef DNS_USE_FTIME_FOR_ID
+#include <sys/timeb.h>
+#endif
+
/* #define NDEBUG */
#ifndef DNS_USE_CPU_CLOCK_FOR_ID
#ifndef DNS_USE_GETTIMEOFDAY_FOR_ID
#ifndef DNS_USE_OPENSSL_FOR_ID
+#ifndef DNS_USE_FTIME_FOR_ID
#error Must configure at least one id generation method.
#error Please see the documentation.
#endif
#endif
#endif
+#endif
/* #define _POSIX_C_SOURCE 200507 */
#define _GNU_SOURCE
#include <string.h>
#include <fcntl.h>
+#ifdef HAVE_SYS_TIME_H
#include <sys/time.h>
+#endif
#ifdef HAVE_STDINT_H
#include <stdint.h>
#endif
#include <string.h>
#include <errno.h>
#include <assert.h>
+#ifdef HAVE_UNISTD_H
#include <unistd.h>
+#endif
#include <limits.h>
#include <sys/stat.h>
#include <ctype.h>
#include "evutil.h"
#include "log.h"
#ifdef WIN32
-#include <windows.h>
#include <winsock2.h>
+#include <windows.h>
#include <iphlpapi.h>
+#include <io.h>
#else
#include <sys/socket.h>
#include <netinet/in.h>
#endif
#include <event.h>
-#define u64 uint64_t
-#define u32 uint32_t
-#define u16 uint16_t
-#define u8 uint8_t
+#define u64 ev_uint64_t
+#define u32 ev_uint32_t
+#define u16 ev_uint16_t
+#define u8 ev_uint8_t
+
+#ifdef WIN32
+#define snprintf _snprintf
+#define open _open
+#define read _read
+#define close _close
+#define strdup _strdup
+#endif
#define MAX_ADDRS 32 /* maximum number of addresses from a single packet */
/* which we bother recording */
static void evdns_requests_pump_waiting_queue(void);
static u16 transaction_id_pick(void);
static struct request *request_new(int type, const char *name, int flags, evdns_callback_type callback, void *ptr);
-static void request_submit(struct request *req);
+static void request_submit(struct request *const req);
static int server_request_free(struct server_request *req);
static void server_request_free_answers(struct server_request *req);
trans_id = ts.tv_nsec & 0xffff;
#endif
+#ifdef DNS_USE_FTIME_FOR_ID
+ struct _timeb tb;
+ _ftime(&tb);
+ trans_id = tb.millitm & 0xffff;
+#endif
+
#ifdef DNS_USE_GETTIMEOFDAY_FOR_ID
struct timeval tv;
gettimeofday(&tv, NULL);
if (r < 0)
goto overflow;
j = r;
- _t = htons( (j-name_start) );
+ _t = htons( (short) (j-name_start) );
memcpy(buf+len_idx, &_t, 2);
} else {
APPEND16(item->datalen);
extern "C" {
#endif
-#include <stdint.h>
+/* For integer types. */
+#include <evutil.h>
/** Error codes 0-5 are as described in RFC 1035. */
#define DNS_ERR_NONE 0
occurred (see above)
@see resolv.conf(3), evdns_config_windows_nameservers()
*/
-int evdns_resolv_conf_parse(int flags, const char *filename);
+int evdns_resolv_conf_parse(int flags, const char *const filename);
/**
@param fn the new callback, or NULL to use the default.
*/
-void evdns_set_transaction_id_fn(uint16_t (*fn)(void));
+void evdns_set_transaction_id_fn(ev_uint16_t (*fn)(void));
#define DNS_NO_SEARCH 1
#ifdef _EVENT_HAVE_SYS_TYPES_H
#include <sys/types.h>
#endif
+#ifdef _EVENT_HAVE_SYS_TIME_H
#include <sys/time.h>
+#endif
+#ifdef _EVENT_HAVE_STDINT_H
#include <stdint.h>
+#endif
#include <stdarg.h>
+/* For int types. */
+#include <evutil.h>
+
#ifdef WIN32
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
void evtag_init(void);
-void evtag_marshal(struct evbuffer *evbuf, uint8_t tag, const void *data,
- uint32_t len);
+void evtag_marshal(struct evbuffer *evbuf, ev_uint8_t tag, const void *data,
+ ev_uint32_t len);
/**
Encode an integer and store it in an evbuffer.
@param evbuf evbuffer to store the encoded number
@param number a 32-bit integer
*/
-void encode_int(struct evbuffer *evbuf, uint32_t number);
+void encode_int(struct evbuffer *evbuf, ev_uint32_t number);
-void evtag_marshal_int(struct evbuffer *evbuf, uint8_t tag, uint32_t integer);
+void evtag_marshal_int(struct evbuffer *evbuf, ev_uint8_t tag, ev_uint32_t integer);
-void evtag_marshal_string(struct evbuffer *buf, uint8_t tag,
+void evtag_marshal_string(struct evbuffer *buf, ev_uint8_t tag,
const char *string);
-void evtag_marshal_timeval(struct evbuffer *evbuf, uint8_t tag,
+void evtag_marshal_timeval(struct evbuffer *evbuf, ev_uint8_t tag,
struct timeval *tv);
void evtag_test(void);
-int evtag_unmarshal(struct evbuffer *src, uint8_t *ptag, struct evbuffer *dst);
-int evtag_peek(struct evbuffer *evbuf, uint8_t *ptag);
-int evtag_peek_length(struct evbuffer *evbuf, uint32_t *plength);
-int evtag_payload_length(struct evbuffer *evbuf, uint32_t *plength);
+int evtag_unmarshal(struct evbuffer *src, ev_uint8_t *ptag, struct evbuffer *dst);
+int evtag_peek(struct evbuffer *evbuf, ev_uint8_t *ptag);
+int evtag_peek_length(struct evbuffer *evbuf, ev_uint32_t *plength);
+int evtag_payload_length(struct evbuffer *evbuf, ev_uint32_t *plength);
int evtag_consume(struct evbuffer *evbuf);
-int evtag_unmarshal_int(struct evbuffer *evbuf, uint8_t need_tag,
- uint32_t *pinteger);
+int evtag_unmarshal_int(struct evbuffer *evbuf, ev_uint8_t need_tag,
+ ev_uint32_t *pinteger);
-int evtag_unmarshal_fixed(struct evbuffer *src, uint8_t need_tag, void *data,
+int evtag_unmarshal_fixed(struct evbuffer *src, ev_uint8_t need_tag, void *data,
size_t len);
-int evtag_unmarshal_string(struct evbuffer *evbuf, uint8_t need_tag,
+int evtag_unmarshal_string(struct evbuffer *evbuf, ev_uint8_t need_tag,
char **pstring);
-int evtag_unmarshal_timeval(struct evbuffer *evbuf, uint8_t need_tag,
+int evtag_unmarshal_timeval(struct evbuffer *evbuf, ev_uint8_t need_tag,
struct timeval *ptv);
#ifdef __cplusplus
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#include <sys/types.h>
-#include <sys/param.h>
-
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
+#ifdef HAVE_SYS_TYPES_H
+#include <sys/types.h>
+#endif
+#ifdef HAVE_SYS_PARAM_H
+#include <sys/param.h>
+#endif
+
#ifdef WIN32
#define WIN32_LEAN_AND_MEAN
+#include <winsock2.h>
#include <windows.h>
#undef WIN32_LEAN_AND_MEAN
#else
#ifndef WIN32
#include <syslog.h>
#endif
+#ifdef HAVE_UNISTD_H
#include <unistd.h>
+#endif
#include "event.h"
#include "log.h"
#endif
#ifdef HAVE_SYS_TIME_H
#include <sys/time.h>
-#else
-#include <sys/_time.h>
#endif
#include <sys/queue.h>
#include <stdio.h>
#define evutil_timerisset(tvp) ((tvp)->tv_sec || (tvp)->tv_usec)
#endif
+#ifdef _EVENT_HAVE_STDINT_H
+#include <stdint.h>
+#define ev_uint64_t uint64_t
+#define ev_uint32_t uint32_t
+#define ev_uint16_t uint16_t
+#define ev_uint8_t uint8_t
+#elif defined(WIN32)
+#define ev_uint64_t __uint64_t
+#define ev_uint32_t unsigned int
+#define ev_uint16_t unsigned short
+#define ev_uint8_t unsigned char
+#endif
+
#ifdef __cplusplus
}
#endif
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#include <sys/param.h>
-#include <sys/types.h>
-
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
+#ifdef HAVE_SYS_PARAM_H
+#include <sys/param.h>
+#endif
+#ifdef HAVE_SYS_TYPES_H
+#include <sys/types.h>
+#endif
+
#ifdef HAVE_SYS_TIME_H
#include <sys/time.h>
#endif
#include <netdb.h>
#endif
+#ifdef WIN32
+#include <winsock2.h>
+#endif
+
#include <assert.h>
#include <ctype.h>
#include <errno.h>
#endif
#include <signal.h>
#include <time.h>
+#ifdef HAVE_UNISTD_H
#include <unistd.h>
+#endif
+#ifdef HAVE_FCNTL_H
#include <fcntl.h>
+#endif
#undef timeout_pending
#undef timeout_initialized
#include "log.h"
#include "http-internal.h"
+#ifdef WIN32
+#define snprintf _snprintf
+#define strcasecmp _stricmp
+#define strncasecmp _strnicmp
+#define strdup _strdup
+#endif
+
#ifndef HAVE_GETADDRINFO
struct addrinfo {
int ai_family;
int min_heap_erase(min_heap_t* s, struct event* e)
{
- if(-1u != e->min_heap_idx)
+ if(((unsigned int)-1) != e->min_heap_idx)
{
min_heap_shift_down_(s, e->min_heap_idx, s->p[--s->n]);
e->min_heap_idx = -1;
#include <sys/types.h>
#ifdef HAVE_SYS_TIME_H
#include <sys/time.h>
-#else
-#include <sys/_time.h>
#endif
#include <sys/queue.h>
#ifdef HAVE_SYS_SOCKET_H
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#ifdef HAVE_UNISTD_H
#include <unistd.h>
+#endif
#include <errno.h>
#ifdef HAVE_FCNTL_H
#include <fcntl.h>
{
static char signals[100];
struct event *ev = arg;
+#ifdef WIN32
+ SSIZE_T n;
+#else
ssize_t n;
+#endif
n = recv(fd, signals, sizeof(signals), 0);
if (n == -1)