Use MTU from interface definition

This commit is contained in:
Neil Alexander 2018-01-15 14:39:07 +00:00
parent d7be706413
commit 62c45e7cc7

View File

@ -83,7 +83,7 @@ func (tun *tunDevice) setupAddress(addr string) error {
var ir ifreq var ir ifreq
copy(ir.ifr_name[:], tun.iface.Name()) copy(ir.ifr_name[:], tun.iface.Name())
ir.ifru_mtu = 1280 ir.ifru_mtu = uint32(tun.mtu)
tun.core.log.Printf("Interface name: %s", ar.ifra_name) tun.core.log.Printf("Interface name: %s", ar.ifra_name)
tun.core.log.Printf("Interface IPv6: %s", addr) tun.core.log.Printf("Interface IPv6: %s", addr)