panic: invalid allocation length: 0x0 goroutine 265692 [running]: gvisor.googlesource.com/gvisor/pkg/sentry/platform/filemem.(*FileMem).Allocate(0xc4202c6000, 0x0, 0x3, 0x0, 0x0, 0x0, 0x0) pkg/sentry/platform/filemem/filemem.go:232 +0x66f gvisor.googlesource.com/gvisor/pkg/sentry/fs/tmpfs.(*fileReadWriter).WriteFromBlocks(0xc4201241f0, 0x7fdac4930080, 0xffffffffffffffff, 0x0, 0x25, 0x0, 0x0, 0x0) pkg/sentry/fs/tmpfs/inode_file.go:411 +0x2a8 gvisor.googlesource.com/gvisor/pkg/sentry/safemem.(Writer).WriteFromBlocks-fm(0x7fdac4930080, 0xffffffffffffffff, 0x0, 0x25, 0x200000a5, 0x7fdac4930080, 0xffffffffffffffff) pkg/sentry/mm/io.go:309 +0x57 gvisor.googlesource.com/gvisor/pkg/sentry/mm.(*MemoryManager).withInternalMappings(0xc42104e000, 0xc731e0, 0xc42041a040, 0x20000080, 0x200000a5, 0x1, 0xc420690c20, 0x10d1d18, 0x3a49419dd780e, 0xc420690b68) pkg/sentry/mm/io.go:464 +0x72c gvisor.googlesource.com/gvisor/pkg/sentry/mm.(*MemoryManager).withVecInternalMappings(0xc42104e000, 0xc731e0, 0xc42041a040, 0x0, 0x1, 0x20000080, 0x25, 0xc400000001, 0xc420690c20, 0x4, ...) pkg/sentry/mm/io.go:533 +0x7f1 gvisor.googlesource.com/gvisor/pkg/sentry/mm.(*MemoryManager).CopyInTo(0xc42104e000, 0xc731e0, 0xc42041a040, 0x0, 0x1, 0x20000080, 0x25, 0xc65da0, 0xc4201241f0, 0x0, ...) pkg/sentry/mm/io.go:309 +0x17c gvisor.googlesource.com/gvisor/pkg/sentry/usermem.IOSequence.CopyInTo(0xc71a40, 0xc42104e000, 0x0, 0x1, 0x20000080, 0x25, 0x0, 0xc731e0, 0xc42041a040, 0xc65da0, ...) pkg/sentry/usermem/usermem.go:528 +0xad gvisor.googlesource.com/gvisor/pkg/sentry/fs/tmpfs.(*fileInodeOperations).write(0xc420b92000, 0xc731e0, 0xc42041a040, 0xc71a40, 0xc42104e000, 0x0, 0x1, 0x20000080, 0x25, 0x0, ...) pkg/sentry/fs/tmpfs/inode_file.go:289 +0x198 gvisor.googlesource.com/gvisor/pkg/sentry/fs/tmpfs.(*regularFileOperations).Write(0xc4202c2158, 0xc731e0, 0xc42041a040, 0xc421343560, 0xc71a40, 0xc42104e000, 0x0, 0x1, 0x20000080, 0x25, ...) pkg/sentry/fs/tmpfs/file_regular.go:50 +0x89 gvisor.googlesource.com/gvisor/pkg/sentry/fs.(*File).Pwritev(0xc421343560, 0xc731e0, 0xc42041a040, 0xc71a40, 0xc42104e000, 0x0, 0x1, 0x20000080, 0x25, 0x0, ...) pkg/sentry/fs/file.go:294 +0x1c5 gvisor.googlesource.com/gvisor/pkg/sentry/syscalls/linux.performCallback(0xc42073d200, 0xc421343560, 0x200000c0, 0xc4200d00c0, 0xc71a40, 0xc42104e000, 0x0, 0x1, 0x20000080, 0x25, ...) pkg/sentry/syscalls/linux/sys_aio.go:264 +0x2a7 gvisor.googlesource.com/gvisor/pkg/sentry/syscalls/linux.submitCallback.func1() pkg/sentry/syscalls/linux/sys_aio.go:342 +0x7c gvisor.googlesource.com/gvisor/pkg/sentry/fs.Async.func1(0xc420c7e150) pkg/sentry/fs/fs.go:82 +0x4f created by gvisor.googlesource.com/gvisor/pkg/sentry/fs.Async pkg/sentry/fs/fs.go:80 +0x58