mirror of
https://github.com/yggdrasil-network/yggdrasil-go.git
synced 2025-04-28 22:25:07 +03:00
Merge pull request #424 from neilalexander/sessionmtu
Fix bug where MTU was ignored by sessions, resulting in default 1280
This commit is contained in:
commit
75cc25b7f4
1 changed files with 3 additions and 1 deletions
|
@ -283,7 +283,9 @@ func (ss *sessions) createSession(theirPermKey *crypto.BoxPubKey) *sessionInfo {
|
||||||
sinfo.mySesPriv = *priv
|
sinfo.mySesPriv = *priv
|
||||||
sinfo.myNonce = *crypto.NewBoxNonce()
|
sinfo.myNonce = *crypto.NewBoxNonce()
|
||||||
sinfo.theirMTU = 1280
|
sinfo.theirMTU = 1280
|
||||||
sinfo.myMTU = 1280
|
ss.core.config.Mutex.RLock()
|
||||||
|
sinfo.myMTU = uint16(ss.core.config.Current.IfMTU)
|
||||||
|
ss.core.config.Mutex.RUnlock()
|
||||||
now := time.Now()
|
now := time.Now()
|
||||||
sinfo.timeOpened = now
|
sinfo.timeOpened = now
|
||||||
sinfo.time = now
|
sinfo.time = now
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue