summaryrefslogtreecommitdiffhomepage
path: root/pkg/sentry/strace/strace.go
diff options
context:
space:
mode:
authorMichael Pratt <mpratt@google.com>2018-10-08 11:38:02 -0700
committerShentubot <shentubot@google.com>2018-10-08 11:39:54 -0700
commit569c2b06c47d269d961405fa652d45e51860d005 (patch)
treeaabbf7fc7e786d0699d9ea1d34f7048fb4339761 /pkg/sentry/strace/strace.go
parente9e8be661328661b5527f1643727b9a13bbeab48 (diff)
Statfs Namelen should be NAME_MAX not PATH_MAX
We accidentally set the wrong maximum. I've also added PATH_MAX and NAME_MAX to the linux abi package. PiperOrigin-RevId: 216221311 Change-Id: I44805fcf21508831809692184a0eba4cee469633
Diffstat (limited to 'pkg/sentry/strace/strace.go')
-rw-r--r--pkg/sentry/strace/strace.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/pkg/sentry/strace/strace.go b/pkg/sentry/strace/strace.go
index c99c33c33..f2a22aaa5 100644
--- a/pkg/sentry/strace/strace.go
+++ b/pkg/sentry/strace/strace.go
@@ -133,7 +133,7 @@ func dump(t *kernel.Task, addr usermem.Addr, size uint, maximumBlobSize uint) st
}
func path(t *kernel.Task, addr usermem.Addr) string {
- path, err := t.CopyInString(addr, syscall.PathMax)
+ path, err := t.CopyInString(addr, linux.PATH_MAX)
if err != nil {
return fmt.Sprintf("%#x (error decoding path: %s)", addr, err)
}