try making sure the connection closes in the availability checker
This commit is contained in:
@ -281,10 +281,10 @@ func Available() bool {
|
|||||||
log.Println("Connecting error:", err)
|
log.Println("Connecting error:", err)
|
||||||
}
|
}
|
||||||
if conn != nil {
|
if conn != nil {
|
||||||
defer conn.Close()
|
conn.Close()
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
time.Sleep(time.Duration(i*3) * time.Second)
|
time.Sleep(time.Duration(i*10) * time.Second)
|
||||||
}
|
}
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user