mirror of
				https://github.com/caddyserver/caddy.git
				synced 2025-10-31 02:27:19 -04:00 
			
		
		
		
	telemetry: Use int64 constant for duration interval
Otherwise it overflows int type on 32-bit builds
This commit is contained in:
		
							parent
							
								
									b321c00a8f
								
							
						
					
					
						commit
						c667f81866
					
				| @ -209,7 +209,7 @@ func emit(final bool) error { | ||||
| 
 | ||||
| 	// ensure we won't slam the telemetry server; add a little variance | ||||
| 	if reply.NextUpdate < 1*time.Second { | ||||
| 		reply.NextUpdate = defaultUpdateInterval + time.Duration(rand.Intn(int(1*time.Minute))) | ||||
| 		reply.NextUpdate = defaultUpdateInterval + time.Duration(rand.Int63n(int64(1*time.Minute))) | ||||
| 	} | ||||
| 
 | ||||
| 	// schedule the next update (if this wasn't the last one and | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user