Windows: fix build after re-vendoring golang.org/x/sys

Due to the CL https://go-review.googlesource.com/c/39608/ in
x/sys/windows which changed the definitions of STD_INPUT_HANDLE,
STD_OUTPUT_HANDLE and STD_ERROR_HANDLE, we get the following failure
in cmd/dockerd/service_windows.go after re-vendoring x/sys/windows:

  06:29:57 # github.com/docker/docker/cmd/dockerd
  06:29:57 .\service_windows.go:400: cannot use sh (type int) as type uint32 in argument to windows.GetStdHandle

Fix it by adding an explicit type conversion when calling
windows.GetStdHandle.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
This commit is contained in:
Tobias Klauser 2017-07-12 14:49:06 +02:00
Родитель bd13a5a9e0
Коммит e769da88e6
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -397,7 +397,7 @@ func initPanicFile(path string) error {
// it when it panics. Remember the old stderr to restore it before removing
// the panic file.
sh := windows.STD_ERROR_HANDLE
h, err := windows.GetStdHandle(sh)
h, err := windows.GetStdHandle(uint32(sh))
if err != nil {
return err
}