add ticking where there should be

(cherry picked from commit f9a3605601130e5daf765d121d322a37592409ae)
pull/237/head
Jeff Becker 6 years ago committed by Rick V
parent 6913c01524
commit 3fd8f27b01
No known key found for this signature in database
GPG Key ID: C0EDC8723FDC3465

@ -181,7 +181,18 @@ tun_ev_loop(void* unused)
GetQueuedCompletionStatus(tun_event_queue, &size, &listener, &ovl, 100);
if(!alert)
{
// tick listeners on io timeout, this is required to be done every tick
// cycle regardless of any io being done, this manages the internal state
// of the tun logic
for(const auto& tun : tun_listeners)
{
if(tun->t->tick)
tun->t->tick(tun->t);
tun->flush_write();
}
continue; // let's go at it once more
}
if(listener == (ULONG_PTR)~0)
break;
// if we're here, then we got something interesting :>

Loading…
Cancel
Save