Skip to content

Commit

Permalink
[client] Fixed a bug where service loops reconnection after disconnec…
Browse files Browse the repository at this point in the history
…tion.service is shut down and can not exit goroutine (fatedier#3012)

Co-authored-by: lizhisheng <[email protected]>
  • Loading branch information
ChristLZS and ChristLZS authored Jul 12, 2022
1 parent fa7c05c commit 6f25719
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions client/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,10 @@ func (svr *Service) keepControllerWorking() {
}

for {
if atomic.LoadUint32(&svr.exit) != 0 {
return
}

xl.Info("try to reconnect to server...")
conn, session, err := svr.login()
if err != nil {
Expand Down

0 comments on commit 6f25719

Please sign in to comment.