From aa606307b7d10890885e2c76c1652c48a6914db4 Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Mon, 23 Aug 2021 16:44:56 +0200 Subject: [PATCH] vendor: update archive/tar to match Go 1.17.0 Signed-off-by: Sebastiaan van Stijn --- vendor/archive/tar/stat_actime1.go | 1 + vendor/archive/tar/stat_actime2.go | 1 + vendor/archive/tar/stat_unix.go | 1 + vendor/archive/tar/tar_test.go | 9 ++------- 4 files changed, 5 insertions(+), 7 deletions(-) diff --git a/vendor/archive/tar/stat_actime1.go b/vendor/archive/tar/stat_actime1.go index 1bdd1c9dcb..4fdf2a04b3 100644 --- a/vendor/archive/tar/stat_actime1.go +++ b/vendor/archive/tar/stat_actime1.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build aix || linux || dragonfly || openbsd || solaris // +build aix linux dragonfly openbsd solaris package tar diff --git a/vendor/archive/tar/stat_actime2.go b/vendor/archive/tar/stat_actime2.go index 6f17dbe307..5a9a35cbb4 100644 --- a/vendor/archive/tar/stat_actime2.go +++ b/vendor/archive/tar/stat_actime2.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build darwin || freebsd || netbsd // +build darwin freebsd netbsd package tar diff --git a/vendor/archive/tar/stat_unix.go b/vendor/archive/tar/stat_unix.go index db697f51d0..4a5bca0312 100644 --- a/vendor/archive/tar/stat_unix.go +++ b/vendor/archive/tar/stat_unix.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build aix || linux || darwin || dragonfly || freebsd || openbsd || netbsd || solaris // +build aix linux darwin dragonfly freebsd openbsd netbsd solaris package tar diff --git a/vendor/archive/tar/tar_test.go b/vendor/archive/tar/tar_test.go index 91b38401b6..e9fafc7cc7 100644 --- a/vendor/archive/tar/tar_test.go +++ b/vendor/archive/tar/tar_test.go @@ -262,16 +262,11 @@ func TestFileInfoHeaderDir(t *testing.T) { func TestFileInfoHeaderSymlink(t *testing.T) { testenv.MustHaveSymlink(t) - tmpdir, err := os.MkdirTemp("", "TestFileInfoHeaderSymlink") - if err != nil { - t.Fatal(err) - } - defer os.RemoveAll(tmpdir) + tmpdir := t.TempDir() link := filepath.Join(tmpdir, "link") target := tmpdir - err = os.Symlink(target, link) - if err != nil { + if err := os.Symlink(target, link); err != nil { t.Fatal(err) } fi, err := os.Lstat(link)