更新frpc

This commit is contained in:
haidy 2018-05-16 14:15:08 +08:00
parent 9d383a5b5b
commit de3b19cbb2
2 changed files with 4 additions and 1 deletions

View File

@ -172,7 +172,9 @@ func (ctl *Control) Close() error {
ctl.mu.Lock()
defer ctl.mu.Unlock()
ctl.exit = true
ctl.conn.Close()
if ctl.conn != nil {
ctl.conn.Close()
}
ctl.pm.CloseProxies()
return nil
}

View File

@ -119,6 +119,7 @@ func StopFrp() (err error) {
service.Close()
log.Info("frpc is stoped")
os.Exit(0)
return
}