Number of fixes in response to code review
This version cannot complete a handshake. The program will panic upon receiving any message on the UDP socket.
This commit is contained in:
parent
8c34c4cbb3
commit
cba1d6585a
12 changed files with 552 additions and 445 deletions
|
|
@ -168,8 +168,6 @@ func (device *Device) RoutineReadFromTUN() {
|
|||
continue
|
||||
}
|
||||
|
||||
println(size, err)
|
||||
|
||||
elem.packet = elem.packet[:size]
|
||||
|
||||
// lookup peer
|
||||
|
|
@ -210,6 +208,7 @@ func (device *Device) RoutineReadFromTUN() {
|
|||
|
||||
// insert into nonce/pre-handshake queue
|
||||
|
||||
signalSend(peer.signal.handshakeReset)
|
||||
addToOutboundQueue(peer.queue.nonce, elem)
|
||||
elem = nil
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue