]> www.infradead.org Git - users/dwmw2/openconnect.git/commit
make delay_tunnel consistent with delay_close
authorDaniel Lenski <dlenski@gmail.com>
Sun, 17 May 2020 19:46:43 +0000 (12:46 -0700)
committerDaniel Lenski <dlenski@gmail.com>
Sun, 17 May 2020 20:21:16 +0000 (13:21 -0700)
commit6dc6c55b639d019ea1478f7563193a1861bdbbe5
treea2e26bf9c44df13c87593487feec9d36a207a43e
parent14eb507b22b0783f8c2e94c021d3772df29d2f18
make delay_tunnel consistent with delay_close

1. Decrement counter on each mainloop iteration. Protocol needs to keep setting it to get more mainloop iterations before tunnel setup / close.
2. Value ≥2 causes us to set did_work=1, resulting in no delay before we call mainloop again. Protocol should only set this if it needs to SEND something in order to move things along.
3. Value =1 causes us to set did_work=0, resulting in a delay before we call mainloop again. Protocol should only set this if it needs to RECEIVE something in order to move things along.

Also fix values of NCP_TERM_ACK_{SENT,RECEIVED}.

Signed-off-by: Daniel Lenski <dlenski@gmail.com>
mainloop.c
openconnect-internal.h
ppp.c
ppp.h