aboutsummaryrefslogtreecommitdiffhomepage
path: root/container/path.go
diff options
context:
space:
mode:
Diffstat (limited to 'container/path.go')
-rw-r--r--container/path.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/container/path.go b/container/path.go
index 5170fceb..5ae52dee 100644
--- a/container/path.go
+++ b/container/path.go
@@ -4,7 +4,7 @@ import (
"errors"
"io/fs"
"os"
- "path"
+ "path/filepath"
"strconv"
"strings"
"syscall"
@@ -29,16 +29,16 @@ const (
func toSysroot(name string) string {
name = strings.TrimLeftFunc(name, func(r rune) bool { return r == '/' })
- return path.Join(sysrootPath, name)
+ return filepath.Join(sysrootPath, name)
}
func toHost(name string) string {
name = strings.TrimLeftFunc(name, func(r rune) bool { return r == '/' })
- return path.Join(hostPath, name)
+ return filepath.Join(hostPath, name)
}
func createFile(name string, perm, pperm os.FileMode, content []byte) error {
- if err := os.MkdirAll(path.Dir(name), pperm); err != nil {
+ if err := os.MkdirAll(filepath.Dir(name), pperm); err != nil {
return err
}
f, err := os.OpenFile(name, syscall.O_CREAT|syscall.O_EXCL|syscall.O_WRONLY, perm)