Skip to content

Commit 92ea5e6

Browse files
committed
dap: file explorer uses the wrong path when looking up mounts
It accidentally retrieved the relative path to the mount directory instead of the full path which resulted in always returning the root directory. Signed-off-by: Jonathan A. Sternberg <[email protected]>
1 parent 285dd76 commit 92ea5e6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dap/variables.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -447,7 +447,7 @@ func lookupPath(path string, mounts map[string]gateway.Reference) (remainder str
447447
for p, r := range mounts {
448448
if len(p) > len(prefix) && strings.HasPrefix(path, p) {
449449
prefix = p
450-
remainder, _ = filepath.Rel(prefix, p)
450+
remainder, _ = filepath.Rel(prefix, path)
451451
ref = r
452452
}
453453
}

0 commit comments

Comments
 (0)