]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Re-adding an event to a kqueue modifies the parameters of the original event.
authorneel <neel@FreeBSD.org>
Mon, 5 May 2014 16:30:03 +0000 (16:30 +0000)
committerneel <neel@FreeBSD.org>
Mon, 5 May 2014 16:30:03 +0000 (16:30 +0000)
commit08f11e3e21eb911b00bda0ec0ebaf259fdca2fde
treef2b6904ed620d2df621a56f3d58e2f383bc9cd66
parent5fd692c3b580554aa0926a4aa512022b56575d31
Re-adding an event to a kqueue modifies the parameters of the original event.
However, if the original knote had been disabled then it is not automatically
re-enabled.

Fix this by using EV_ADD to create an mevent and EV_ENABLE to enable it.

Adding a kevent for the first time implicitly enables it so existing callers
of mevent_add() don't need to change.

Reviewed by: grehan
usr.sbin/bhyve/mevent.c