1
0
mirror of https://github.com/fumiama/WireGold.git synced 2026-06-11 12:10:26 +08:00

fix mtu error

This commit is contained in:
fumiama
2021-12-30 23:48:17 +08:00
parent 4013c482b4
commit c207a5daf6
4 changed files with 109 additions and 77 deletions

View File

@@ -57,8 +57,8 @@ func (nc *NIC) Start(m *link.Me) {
logrus.Infoln("[lower] recv write", n, "bytes packet to nic")
}
}()
buf := make([]byte, 4096)
for nc.hasstart { // 从 NIC 发送
buf := make([]byte, 32768) // Ring capacity
for nc.hasstart { // 从 NIC 发送
packet := buf
n, err := nc.ifce.Read(packet)
if err != nil {