Przeglądaj źródła

cluster: Fix shadowed resp variable

The response would never reach the client because it was being
redeclared in the current scope.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Aaron Lehmann 8 lat temu
rodzic
commit
9d127f8de3
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      daemon/cluster/services.go

+ 1 - 1
daemon/cluster/services.go

@@ -193,7 +193,7 @@ func (c *Cluster) UpdateService(serviceIDOrName string, version uint64, spec typ
 			}
 			}
 		}
 		}
 
 
-		resp := &apitypes.ServiceUpdateResponse{}
+		resp = &apitypes.ServiceUpdateResponse{}
 
 
 		// pin image by digest
 		// pin image by digest
 		if os.Getenv("DOCKER_SERVICE_PREFER_OFFLINE_IMAGE") != "1" {
 		if os.Getenv("DOCKER_SERVICE_PREFER_OFFLINE_IMAGE") != "1" {