cri/config: fix range iterator issue in ValidatePluginConfig
Go uses the same address variable while iterating in a range, so use a copy when using its address. Signed-off-by: Gaurav Singh <gaurav1086@gmail.com>
This commit is contained in:
		| @@ -352,6 +352,7 @@ func ValidatePluginConfig(ctx context.Context, c *PluginConfig) error { | ||||
| 			c.Registry.Configs = make(map[string]RegistryConfig) | ||||
| 		} | ||||
| 		for endpoint, auth := range c.Registry.Auths { | ||||
| 			auth := auth | ||||
| 			config := c.Registry.Configs[endpoint] | ||||
| 			config.Auth = &auth | ||||
| 			c.Registry.Configs[endpoint] = config | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Gaurav Singh
					Gaurav Singh