diff options
author | gVisor bot <gvisor-bot@google.com> | 2020-04-21 23:36:34 +0000 |
---|---|---|
committer | gVisor bot <gvisor-bot@google.com> | 2020-04-21 23:36:34 +0000 |
commit | 9e983d691225db47475f4447899e7421864b9b6c (patch) | |
tree | 7fe8779aa43d31d1c6199f5e44458eb1d8a425a7 /pkg/sentry/mm/procfs.go | |
parent | 306c14cdd4e68b95703e78c3877b627d4f7d7885 (diff) | |
parent | 37e01fd2ea6a0e67637975863317be9aae1b02f0 (diff) |
Merge release-20200323.0-207-g37e01fd (automated)
Diffstat (limited to 'pkg/sentry/mm/procfs.go')
-rw-r--r-- | pkg/sentry/mm/procfs.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/sentry/mm/procfs.go b/pkg/sentry/mm/procfs.go index 1ab92f046..6efe5102b 100644 --- a/pkg/sentry/mm/procfs.go +++ b/pkg/sentry/mm/procfs.go @@ -148,7 +148,7 @@ func (mm *MemoryManager) appendVMAMapsEntryLocked(ctx context.Context, vseg vmaI // Do not include the guard page: fs/proc/task_mmu.c:show_map_vma() => // stack_guard_page_start(). - fmt.Fprintf(b, "%08x-%08x %s%s %08x %02x:%02x %d ", + lineLen, _ := fmt.Fprintf(b, "%08x-%08x %s%s %08x %02x:%02x %d ", vseg.Start(), vseg.End(), vma.realPerms, private, vma.off, devMajor, devMinor, ino) // Figure out our filename or hint. @@ -165,7 +165,7 @@ func (mm *MemoryManager) appendVMAMapsEntryLocked(ctx context.Context, vseg vmaI } if s != "" { // Per linux, we pad until the 74th character. - if pad := 73 - b.Len(); pad > 0 { + if pad := 73 - lineLen; pad > 0 { b.WriteString(strings.Repeat(" ", pad)) } b.WriteString(s) |