diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2018-05-18 20:54:45 +0200 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2018-05-18 20:54:45 +0200 |
commit | e7e6819d59ab4c76b28a6d296123256063000d1c (patch) | |
tree | 9e80014b38142eace5288504e2b895b559d80459 /src/timers.c | |
parent | tools: fix errno propagation and messages (diff) | |
download | wireguard-monolithic-historical-e7e6819d59ab4c76b28a6d296123256063000d1c.tar.xz wireguard-monolithic-historical-e7e6819d59ab4c76b28a6d296123256063000d1c.zip |
timers: reinitialize state on init
Diffstat (limited to 'src/timers.c')
-rw-r--r-- | src/timers.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/timers.c b/src/timers.c index dee556d..327a0c1 100644 --- a/src/timers.c +++ b/src/timers.c @@ -186,6 +186,9 @@ void timers_init(struct wireguard_peer *peer) timer_setup(&peer->timer_zero_key_material, expired_zero_key_material, 0); timer_setup(&peer->timer_persistent_keepalive, expired_send_persistent_keepalive, 0); INIT_WORK(&peer->clear_peer_work, queued_expired_zero_key_material); + peer->timer_handshake_attempts = 0; + peer->sent_lastminute_handshake = false; + peer->timer_need_another_keepalive = false; } void timers_stop(struct wireguard_peer *peer) |