mirror of
https://github.com/yggdrasil-network/yggdrasil-go.git
synced 2024-11-23 10:05:17 +00:00
Update default interface MTU to use per-platform instead of global value
This commit is contained in:
parent
4917ea3dd2
commit
4e5627f933
@ -5,8 +5,6 @@ package yggdrasil
|
||||
import "os"
|
||||
import ethernet "github.com/songgao/packets/ethernet"
|
||||
|
||||
const DEFAULT_MTU = 65535
|
||||
|
||||
const IPv6_HEADER_LENGTH = 40
|
||||
const ETHER_HEADER_LENGTH = 14
|
||||
|
||||
|
@ -13,7 +13,7 @@ import water "github.com/neilalexander/water"
|
||||
func getDefaults() tunDefaultParameters {
|
||||
return tunDefaultParameters{
|
||||
maximumIfMTU: 65535,
|
||||
defaultIfMTU: DEFAULT_MTU,
|
||||
defaultIfMTU: 65535,
|
||||
defaultIfName: "auto",
|
||||
defaultIfTAPMode: false,
|
||||
}
|
||||
|
@ -12,7 +12,7 @@ import water "github.com/neilalexander/water"
|
||||
func getDefaults() tunDefaultParameters {
|
||||
return tunDefaultParameters{
|
||||
maximumIfMTU: 65535,
|
||||
defaultIfMTU: DEFAULT_MTU,
|
||||
defaultIfMTU: 65535,
|
||||
defaultIfName: "auto",
|
||||
defaultIfTAPMode: false,
|
||||
}
|
||||
|
@ -18,7 +18,7 @@ import water "github.com/neilalexander/water"
|
||||
func getDefaults() tunDefaultParameters {
|
||||
return tunDefaultParameters{
|
||||
maximumIfMTU: 16384,
|
||||
defaultIfMTU: DEFAULT_MTU,
|
||||
defaultIfMTU: 16384,
|
||||
defaultIfName: "/dev/tap0",
|
||||
defaultIfTAPMode: true,
|
||||
}
|
||||
|
@ -10,7 +10,7 @@ import water "github.com/neilalexander/water"
|
||||
func getDefaults() tunDefaultParameters {
|
||||
return tunDefaultParameters{
|
||||
maximumIfMTU: 65535,
|
||||
defaultIfMTU: DEFAULT_MTU,
|
||||
defaultIfMTU: 65535,
|
||||
defaultIfName: "none",
|
||||
defaultIfTAPMode: false,
|
||||
}
|
||||
|
@ -10,7 +10,7 @@ import "fmt"
|
||||
func getDefaults() tunDefaultParameters {
|
||||
return tunDefaultParameters{
|
||||
maximumIfMTU: 65535,
|
||||
defaultIfMTU: DEFAULT_MTU,
|
||||
defaultIfMTU: 65535,
|
||||
defaultIfName: "auto",
|
||||
defaultIfTAPMode: true,
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user