polish the func comment
This commit is contained in:
@ -227,8 +227,8 @@ func (cc *ClientConn) State() ConnectivityState {
|
|||||||
return cc.state
|
return cc.state
|
||||||
}
|
}
|
||||||
|
|
||||||
// WaitForStateChange returns true when the state changes to something other than the
|
// WaitForStateChange blocks until the state changes to something other than the sourceState
|
||||||
// sourceState and false if timeout fires.
|
// or timeout fires. It returns false if timeout fires and true otherwise.
|
||||||
func (cc *ClientConn) WaitForStateChange(timeout time.Duration, sourceState ConnectivityState) bool {
|
func (cc *ClientConn) WaitForStateChange(timeout time.Duration, sourceState ConnectivityState) bool {
|
||||||
start := time.Now()
|
start := time.Now()
|
||||||
cc.mu.Lock()
|
cc.mu.Lock()
|
||||||
|
Reference in New Issue
Block a user