Commit dd544b60 authored by szh's avatar szh

update

parent b99067bc
...@@ -60,7 +60,7 @@ func Broadcast() { ...@@ -60,7 +60,7 @@ func Broadcast() {
time.Sleep(time.Second*1) time.Sleep(time.Second*1)
continue continue
} }
tlog.Info("broadcasr","ip",ip.IP.String()) tlog.Info("broadcast","eth0",ip.IP.String())
} }
if runningAddr != nil && runningAddr.IP.String() != ip.IP.String() { if runningAddr != nil && runningAddr.IP.String() != ip.IP.String() {
...@@ -80,10 +80,10 @@ func Broadcast() { ...@@ -80,10 +80,10 @@ func Broadcast() {
panic(err) panic(err)
} }
tlog.Info("broadcast","oldip",runningAddr.IP.String(),"newip",ip.IP.String()) tlog.Info("broadcast","oldip",runningAddr.IP.String(),"newip",ip.IP.String())
runningAddr = ip
}
}
runningAddr = ip
_, err = conn.Write([]byte(send)) _, err = conn.Write([]byte(send))
if err != nil{ if err != nil{
tlog.Error("broadcast ","err",err) tlog.Error("broadcast ","err",err)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment