summaryrefslogtreecommitdiffhomepage
path: root/pkg/sentry/fs/overlay.go
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/sentry/fs/overlay.go')
-rw-r--r--pkg/sentry/fs/overlay.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/pkg/sentry/fs/overlay.go b/pkg/sentry/fs/overlay.go
index a63f00e0e..7357d6401 100644
--- a/pkg/sentry/fs/overlay.go
+++ b/pkg/sentry/fs/overlay.go
@@ -16,6 +16,7 @@ package fs
import (
"fmt"
+ "strings"
"sync"
"gvisor.googlesource.com/gvisor/pkg/log"
@@ -76,6 +77,12 @@ func XattrOverlayWhiteout(name string) string {
return XattrOverlayWhiteoutPrefix + name
}
+// isXattrOverlay returns whether the given extended attribute configures the
+// overlay.
+func isXattrOverlay(name string) bool {
+ return strings.HasPrefix(name, XattrOverlayPrefix)
+}
+
// NewOverlayRoot produces the root of an overlay.
//
// Preconditions: