test2
This commit is contained in:
parent
e25b10d931
commit
1918bc3328
3
dip.go
3
dip.go
|
@ -75,10 +75,11 @@ func (group *DIPGroup) Choose(addr string) {
|
|||
SetAddrForward(group.IPTableNum, addr, ip)
|
||||
} else {
|
||||
restartAddr := "http://" + group.Current.Host + ":8800/pppoe/restart"
|
||||
if _, err := grequests.Get(restartAddr, nil); err != nil {
|
||||
if resp, err := grequests.Get(restartAddr, nil); err != nil {
|
||||
log.Println(err)
|
||||
group.Current.ActiveTime += 12
|
||||
} else {
|
||||
defer resp.Close()
|
||||
group.Current = dhost
|
||||
group.Current.ActiveTime = now
|
||||
// log.Println("new set addr:", group.Current.Host, "restartAddr:", restartAddr, "resp", resp.Content())
|
||||
|
|
Loading…
Reference in New Issue
Block a user