summaryrefslogtreecommitdiff
path: root/vendor/github.com/containers/buildah/pkg/overlay
diff options
context:
space:
mode:
authortomsweeneyredhat <tsweeney@redhat.com>2022-08-08 22:17:35 -0400
committertomsweeneyredhat <tsweeney@redhat.com>2022-08-08 22:17:51 -0400
commit7bd886480066ceb097ab5ab101738d6b4fca718f (patch)
treed5133f0ce35b88819e3f77ca4f618b181cde828f /vendor/github.com/containers/buildah/pkg/overlay
parent28607a9238b30be9e2b6dd6476f410eed5314ae9 (diff)
Bump to Buildah v1.27.0
As the title says. Vendor Buildah v1.27.0 into Podman in preparation for Buildah v4.2 [No New Tests Needed] Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
Diffstat (limited to 'vendor/github.com/containers/buildah/pkg/overlay')
-rw-r--r--vendor/github.com/containers/buildah/pkg/overlay/overlay.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/vendor/github.com/containers/buildah/pkg/overlay/overlay.go b/vendor/github.com/containers/buildah/pkg/overlay/overlay.go
index 6ab10b13c..07bb2195a 100644
--- a/vendor/github.com/containers/buildah/pkg/overlay/overlay.go
+++ b/vendor/github.com/containers/buildah/pkg/overlay/overlay.go
@@ -250,7 +250,7 @@ func Unmount(contentDir string) error {
}
// Ignore EINVAL as the specified merge dir is not a mount point
- if err := unix.Unmount(mergeDir, 0); err != nil && !os.IsNotExist(err) && err != unix.EINVAL {
+ if err := unix.Unmount(mergeDir, 0); err != nil && !errors.Is(err, os.ErrNotExist) && err != unix.EINVAL {
return fmt.Errorf("unmount overlay %s: %w", mergeDir, err)
}
return nil
@@ -259,7 +259,7 @@ func Unmount(contentDir string) error {
func recreate(contentDir string) error {
st, err := system.Stat(contentDir)
if err != nil {
- if os.IsNotExist(err) {
+ if errors.Is(err, os.ErrNotExist) {
return nil
}
return fmt.Errorf("failed to stat overlay upper directory: %w", err)
@@ -293,7 +293,7 @@ func CleanupContent(containerDir string) (Err error) {
files, err := ioutil.ReadDir(contentDir)
if err != nil {
- if os.IsNotExist(err) {
+ if errors.Is(err, os.ErrNotExist) {
return nil
}
return fmt.Errorf("read directory: %w", err)
@@ -305,7 +305,7 @@ func CleanupContent(containerDir string) (Err error) {
}
}
- if err := os.RemoveAll(contentDir); err != nil && !os.IsNotExist(err) {
+ if err := os.RemoveAll(contentDir); err != nil && !errors.Is(err, os.ErrNotExist) {
return fmt.Errorf("failed to cleanup overlay directory: %w", err)
}
return nil