|author||Jason A. Donenfeld <Jason@zx2c4.com>||2018-08-04 02:50:51 +0200|
|committer||Jason A. Donenfeld <Jason@zx2c4.com>||2018-08-04 05:14:15 +0200|
|parent||version: bump snapshot (diff)|
send: switch handshake stamp to an atomic
Rather than abusing the handshake lock, we're much better off just using a boring atomic64 for this. It's simpler and performs better. Also, while we're at it, we set the handshake stamp both before and after the calculations, in case the calculations block for a really long time waiting for the RNG to initialize. Otherwise it's possible that when the RNG finally initializes, two handshakes are sent back to back, which isn't sensible.
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions