mirror of
https://github.com/Mrs4s/MiraiGo.git
synced 2025-05-04 19:17:38 +08:00
try to fix panic.
This commit is contained in:
parent
4013c07718
commit
22159e13f9
@ -894,7 +894,7 @@ func (c *QQClient) connect() error {
|
||||
if c.currServerIndex == len(c.servers) {
|
||||
c.currServerIndex = 0
|
||||
}
|
||||
if err != nil {
|
||||
if err != nil || conn == nil {
|
||||
c.retryTimes++
|
||||
if c.retryTimes > len(c.servers) {
|
||||
return errors.New("network error")
|
||||
|
Loading…
x
Reference in New Issue
Block a user