summaryrefslogtreecommitdiffstats
path: root/third_party/libevent/test/bench.c
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/libevent/test/bench.c')
-rw-r--r--third_party/libevent/test/bench.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/third_party/libevent/test/bench.c b/third_party/libevent/test/bench.c
index 48fd32a..c976932 100644
--- a/third_party/libevent/test/bench.c
+++ b/third_party/libevent/test/bench.c
@@ -44,7 +44,7 @@
#include <windows.h>
#else
#include <sys/socket.h>
-#include <sys/signal.h>
+#include <signal.h>
#include <sys/resource.h>
#endif
#include <fcntl.h>
@@ -63,12 +63,10 @@ static int *pipes;
static int num_pipes, num_active, num_writes;
static struct event *events;
-
-
static void
read_cb(int fd, short which, void *arg)
{
- int idx = (int) arg, widx = idx + 1;
+ long idx = (long) arg, widx = idx + 1;
u_char ch;
count += read(fd, &ch, sizeof(ch));
@@ -84,7 +82,8 @@ read_cb(int fd, short which, void *arg)
static struct timeval *
run_once(void)
{
- int *cp, i, space;
+ int *cp, space;
+ long i;
static struct timeval ts, te;
for (cp = pipes, i = 0; i < num_pipes; i++, cp += 2) {