aboutsummaryrefslogtreecommitdiffstats
path: root/driver/socket.c
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2021-08-03 12:52:55 +0200
committerJason A. Donenfeld <Jason@zx2c4.com>2021-08-03 12:54:25 +0200
commit4bd8a2416920692e11473745e50d8122e6a22475 (patch)
treeaf02b0419f50e596cce60134bb8c40ae37280364 /driver/socket.c
parentdriver: socket: flip mask around on route lookup (diff)
downloadwireguard-nt-4bd8a2416920692e11473745e50d8122e6a22475.tar.xz
wireguard-nt-4bd8a2416920692e11473745e50d8122e6a22475.zip
driver: socket: increment local endpoint update generation
Otherwise we wind up retrying and doing the routing generation comparison at the top needlessly. Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'driver/socket.c')
-rw-r--r--driver/socket.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/driver/socket.c b/driver/socket.c
index c0e6660..36c310b 100644
--- a/driver/socket.c
+++ b/driver/socket.c
@@ -319,7 +319,7 @@ retry:
}
else
BestIndex = 0;
- ++Endpoint->UpdateGeneration;
+ ++Endpoint->UpdateGeneration, ++UpdateGeneration;
ExReleaseSpinLockExclusive(&Peer->EndpointLock, *Irql);
if (!BestIndex)
return STATUS_BAD_NETWORK_PATH;