X-Git-Url: http://www.git.cypherpunks.ru/?a=blobdiff_plain;f=src%2Fcypherpunks.ru%2Fgovpn%2Fclient%2Fudp.go;h=70000d3e5f190d5daf322e3b6a97773d62859416;hb=70e70dfded87dc2d737160444829c58ed8ed2fa0;hp=bb7045ac711778f25e8a9f8d839dea3ae9f11d92;hpb=eb63bd7cb200da72cc782f4fef873ebfdc6c0eba;p=govpn.git diff --git a/src/cypherpunks.ru/govpn/client/udp.go b/src/cypherpunks.ru/govpn/client/udp.go index bb7045a..70000d3 100644 --- a/src/cypherpunks.ru/govpn/client/udp.go +++ b/src/cypherpunks.ru/govpn/client/udp.go @@ -1,6 +1,6 @@ /* GoVPN -- simple secure free software virtual private network daemon -Copyright (C) 2014-2017 Sergey Matveev +Copyright (C) 2014-2018 Sergey Matveev This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -93,7 +93,7 @@ MainCycle: continue } govpn.Printf(`[handshake-completed remote="%s"]`, c.config.RemoteAddress) - c.knownPeers = govpn.KnownPeers(map[string]**govpn.Peer{c.config.RemoteAddress: &peer}) + c.knownPeers.Store(c.config.RemoteAddress, &peer) if c.firstUpCall { go govpn.ScriptCall(c.config.UpPath, c.config.InterfaceName, c.config.RemoteAddress) c.firstUpCall = false