From 9d12bc2573d6b3945e48cb1f0a0a6d7e0454082f Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Fri, 25 Oct 2019 00:21:52 +0200 Subject: [PATCH] pkg/system: make OSVersion an alias for hcsshim OSVersion Signed-off-by: Sebastiaan van Stijn --- pkg/system/syscall_windows.go | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/pkg/system/syscall_windows.go b/pkg/system/syscall_windows.go index 67bec7e30b..1711130bc3 100644 --- a/pkg/system/syscall_windows.go +++ b/pkg/system/syscall_windows.go @@ -1,7 +1,6 @@ package system // import "github.com/docker/docker/pkg/system" import ( - "fmt" "syscall" "unsafe" @@ -62,7 +61,7 @@ var ( // OSVersion is a wrapper for Windows version information // https://msdn.microsoft.com/en-us/library/windows/desktop/ms724439(v=vs.85).aspx -type OSVersion osversion.OSVersion +type OSVersion = osversion.OSVersion // https://msdn.microsoft.com/en-us/library/windows/desktop/ms724833(v=vs.85).aspx type osVersionInfoEx struct { @@ -83,11 +82,7 @@ type osVersionInfoEx struct { // dockerd.exe must be manifested to get the correct version information. // Deprecated: use github.com/Microsoft/hcsshim/osversion.Get() instead func GetOSVersion() OSVersion { - return OSVersion(osversion.Get()) -} - -func (osv OSVersion) ToString() string { - return fmt.Sprintf("%d.%d.%d", osv.MajorVersion, osv.MinorVersion, osv.Build) + return osversion.Get() } // IsWindowsClient returns true if the SKU is client