Skip to content

Commit 9b45920

Browse files
authored
Merge pull request #3252 from mlgibbons/caching-fix
Fix Windows cache path issues with directory hierarchies and lower-case drive letters
2 parents 457d671 + fb68def commit 9b45920

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

Diff for: pkg/minikube/machine/cache_images.go

+1-4
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ func hasWindowsDriveLetter(s string) bool {
144144
}
145145

146146
drive := s[:3]
147-
for _, b := range "CDEFGHIJKLMNOPQRSTUVWXYZAB" {
147+
for _, b := range "CDEFGHIJKLMNOPQRSTUVWXYZABcdefghijklmnopqrstuvwxyzab" {
148148
if d := string(b) + ":"; drive == d+`\` || drive == d+`/` {
149149
return true
150150
}
@@ -160,9 +160,6 @@ func replaceWinDriveLetterToVolumeName(s string) (string, error) {
160160
return "", err
161161
}
162162
path := vname + s[3:]
163-
if _, err := os.Stat(filepath.Dir(path)); err != nil {
164-
return "", err
165-
}
166163

167164
return path, nil
168165
}

0 commit comments

Comments
 (0)