Commit ac91b19c authored by Kubernetes Submit Queue's avatar Kubernetes Submit Queue Committed by GitHub

Merge pull request #52718 from foxyriver/ingress

Automatic merge from submit-queue (batch tested with PRs 51902, 52718, 52687, 52137, 52697). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.. stop the Timer **What this PR does / why we need it**: Ticker stop twice, and does not stop Timer.
parents 2b24df34 0f01a355
...@@ -430,7 +430,7 @@ func (c *sioClient) WaitForAttachedDevice(token string) (string, error) { ...@@ -430,7 +430,7 @@ func (c *sioClient) WaitForAttachedDevice(token string) (string, error) {
ticker := time.NewTicker(time.Second) ticker := time.NewTicker(time.Second)
defer ticker.Stop() defer ticker.Stop()
timer := time.NewTimer(30 * time.Second) timer := time.NewTimer(30 * time.Second)
defer ticker.Stop() defer timer.Stop()
for { for {
select { select {
...@@ -464,7 +464,7 @@ func (c *sioClient) WaitForDetachedDevice(token string) error { ...@@ -464,7 +464,7 @@ func (c *sioClient) WaitForDetachedDevice(token string) error {
ticker := time.NewTicker(time.Second) ticker := time.NewTicker(time.Second)
defer ticker.Stop() defer ticker.Stop()
timer := time.NewTimer(30 * time.Second) timer := time.NewTimer(30 * time.Second)
defer ticker.Stop() defer timer.Stop()
for { for {
select { select {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment