From: ayin Date: Mon, 12 Nov 2007 09:44:37 +0000 (+0000) Subject: Fix double increment bug. X-Git-Tag: rel-0_9~13 X-Git-Url: https://git.llucax.com/software/libev.git/commitdiff_plain/42d2222c89438fb21dc75622c71c99e2eb2f195f Fix double increment bug. --- diff --git a/ev_kqueue.c b/ev_kqueue.c index eeaea3e..701f6d2 100644 --- a/ev_kqueue.c +++ b/ev_kqueue.c @@ -39,7 +39,8 @@ kqueue_change (EV_P_ int fd, int filter, int flags, int fflags) { struct kevent *ke; - array_needsize (struct kevent, kqueue_changes, kqueue_changemax, ++kqueue_changecnt, ); + ++kqueue_changecnt; + array_needsize (struct kevent, kqueue_changes, kqueue_changemax, kqueue_changecnt, ); ke = &kqueue_changes [kqueue_changecnt - 1]; memset (ke, 0, sizeof (struct kevent));