1
0
forked from JOJ/JOJ3

fix(executor/sandbox): use relative path

This commit is contained in:
张泊明518370910136 2025-06-26 00:48:33 -04:00
parent aa377c1046
commit be7ed98c1b
Signed by untrusted user: 张泊明518370910136
GPG Key ID: D47306D7062CDA9D

View File

@ -52,8 +52,12 @@ func convertPBCopyIn(
if err != nil {
return nil
}
relPath, err := filepath.Rel(copyInDir, path)
if err != nil {
return nil
}
if !info.IsDir() {
copyIn[path] = stage.CmdFile{Src: &absPath}
copyIn[relPath] = stage.CmdFile{Src: &absPath}
}
return nil
})