mirror of
https://github.com/cuberite/libevent.git
synced 2025-09-17 08:17:42 -04:00
Fix kquue correctness test on x84_64
Apparently, in our configure.in check for a working kqueue, we were leaving some fields unset that seemed to irritate 64-bit kqueue a lot. Found by Christopher Layne
This commit is contained in:
parent
4c32b9de2c
commit
6123d1298f
@ -330,13 +330,14 @@ main(int argc, char **argv)
|
||||
if ((kq = kqueue()) == -1)
|
||||
exit(1);
|
||||
|
||||
memset(&ev, 0, sizeof(ev));
|
||||
ev.ident = fd[[1]];
|
||||
ev.filter = EVFILT_WRITE;
|
||||
ev.flags = EV_ADD | EV_ENABLE;
|
||||
n = kevent(kq, &ev, 1, NULL, 0, NULL);
|
||||
if (n == -1)
|
||||
exit(1);
|
||||
|
||||
|
||||
read(fd[[0]], buf, sizeof(buf));
|
||||
|
||||
ts.tv_sec = 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user