From 311d87dbebbb0238196d3aa13fd9a37f655e1fc3 Mon Sep 17 00:00:00 2001 From: Alex Brainman Date: Wed, 28 Nov 2018 19:57:13 +1100 Subject: [PATCH] debug/pe: use ws2_32.dll in TestImportTableInUnknownSection Apparently (see https://github.com/golang/go/issues/27904#issuecomment-442140627 for details) kernel32.dll file is not present on windows/arm, so use ws2_32.dll instead. ws2_32.dll imports table also lives in '.rdata' section, so ws2_32.dll is as good as kernel32.dll for testing issue #16103. Updates #27904 Change-Id: Ibc72b24eea9a4d85abd371ffdcf00442e711b745 Reviewed-on: https://go-review.googlesource.com/c/151480 Reviewed-by: Brad Fitzpatrick Run-TryBot: Brad Fitzpatrick --- src/debug/pe/file_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/debug/pe/file_test.go b/src/debug/pe/file_test.go index 5b9fe521d2..9613af3a3c 100644 --- a/src/debug/pe/file_test.go +++ b/src/debug/pe/file_test.go @@ -603,9 +603,9 @@ func TestImportTableInUnknownSection(t *testing.T) { t.Skip("skipping Windows-only test") } - // kernel32.dll import table is located in ".rdata" section, + // ws2_32.dll import table is located in ".rdata" section, // so it is good enough to test issue #16103. - const filename = "kernel32.dll" + const filename = "ws2_32.dll" path, err := exec.LookPath(filename) if err != nil { t.Fatalf("unable to locate required file %q in search path: %s", filename, err) -- 2.50.0