summaryrefslogtreecommitdiff
path: root/src/keypair.go
diff options
context:
space:
mode:
authorMathias Hall-Andersen <mathias@hall-andersen.dk>2017-07-08 23:51:26 +0200
committerMathias Hall-Andersen <mathias@hall-andersen.dk>2017-07-08 23:51:26 +0200
commit4ad62aaa6aa269f08c0fdc9c139e6d5417e21746 (patch)
tree2105f65bc61b0fb842ac44c11a81150a8bb9a909 /src/keypair.go
parent5c1ccbddf0c6fdfd98cb3204c1cd4726862855f2 (diff)
downloadwireguard-go-4ad62aaa6aa269f08c0fdc9c139e6d5417e21746.tar.gz
wireguard-go-4ad62aaa6aa269f08c0fdc9c139e6d5417e21746.zip
Improved timer state machine
Diffstat (limited to 'src/keypair.go')
-rw-r--r--src/keypair.go13
1 files changed, 0 insertions, 13 deletions
diff --git a/src/keypair.go b/src/keypair.go
index 3caa0c8..b24dbe4 100644
--- a/src/keypair.go
+++ b/src/keypair.go
@@ -23,19 +23,6 @@ type KeyPairs struct {
next *KeyPair // not yet "confirmed by transport"
}
-/* Called during recieving to confirm the handshake
- * was completed correctly
- */
-func (kp *KeyPairs) Used(key *KeyPair) {
- if key == kp.next {
- kp.mutex.Lock()
- kp.previous = kp.current
- kp.current = key
- kp.next = nil
- kp.mutex.Unlock()
- }
-}
-
func (kp *KeyPairs) Current() *KeyPair {
kp.mutex.RLock()
defer kp.mutex.RUnlock()