Bug 1000: avoid timer() starvation during high load conditions
ChangeLog:
Bug 1000: additionally fix timer() starvation during high load
bk: 47b7f26fO1WZPiVElSf7HPD28BwH3Q
* [Bug 1000] allow implicit receive buffer allocation for Windows
fixes startup for windows systems with many interfaces
reduces dropped packets on network bursts
+ additionally fix timer() starvation during high load
---
(4.2.4p4) Released by Harlan Stenn <stenn@ntp.org>
rbuf = get_full_recv_buffer();
while (rbuf != NULL)
{
+ if (alarm_flag)
+ {
+ was_alarmed = 1;
+ alarm_flag = 0;
+ }
UNBLOCK_IO_AND_ALARM();
+ if (was_alarmed)
+ { /* avoid timer starvation during lengthy I/O handling */
+ timer();
+ was_alarmed = 0;
+ }
+
/*
* Call the data procedure to handle each received
* packet.