mirror of https://github.com/grpc/grpc-go.git
				
				
				
			balancer/weightedroundrobin: fix ticker leak on update (#6643)
This commit is contained in:
		
							parent
							
								
									92f5ba9783
								
							
						
					
					
						commit
						1457a96132
					
				|  | @ -369,6 +369,7 @@ func (p *picker) start(ctx context.Context) { | |||
| 	} | ||||
| 	go func() { | ||||
| 		ticker := time.NewTicker(time.Duration(p.cfg.WeightUpdatePeriod)) | ||||
| 		defer ticker.Stop() | ||||
| 		for { | ||||
| 			select { | ||||
| 			case <-ctx.Done(): | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue