mirror of
https://github.com/fumiama/WireGold.git
synced 2026-07-02 00:20:26 +08:00
rm tic
This commit is contained in:
@@ -5,7 +5,6 @@ import (
|
|||||||
"os"
|
"os"
|
||||||
"os/exec"
|
"os/exec"
|
||||||
"strconv"
|
"strconv"
|
||||||
"time"
|
|
||||||
|
|
||||||
"github.com/fumiama/water"
|
"github.com/fumiama/water"
|
||||||
"github.com/fumiama/water/waterutil"
|
"github.com/fumiama/water/waterutil"
|
||||||
@@ -63,11 +62,7 @@ func (nc *NIC) Start(m *link.Me) {
|
|||||||
buf2 := make([]byte, m.MTU()+68) // 增加报头长度与 TEA 冗余
|
buf2 := make([]byte, m.MTU()+68) // 增加报头长度与 TEA 冗余
|
||||||
off := 0
|
off := 0
|
||||||
isrev := false
|
isrev := false
|
||||||
t := time.NewTicker(time.Millisecond)
|
for nc.hasstart { // 从 NIC 发送
|
||||||
for range t.C { // 从 NIC 发送
|
|
||||||
if !nc.hasstart {
|
|
||||||
break
|
|
||||||
}
|
|
||||||
var packet []byte
|
var packet []byte
|
||||||
if off > 0 && !isrev {
|
if off > 0 && !isrev {
|
||||||
packet = buf2
|
packet = buf2
|
||||||
|
|||||||
Reference in New Issue
Block a user