From 4d4d47f0c0a21d3404d2edae527b187d62daa3c8 Mon Sep 17 00:00:00 2001 From: Adin Scannell Date: Mon, 10 Feb 2020 13:04:29 -0800 Subject: Add contextual note. PiperOrigin-RevId: 294285723 --- pkg/sentry/fsimpl/gofer/directory.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'pkg/sentry/fsimpl/gofer/directory.go') diff --git a/pkg/sentry/fsimpl/gofer/directory.go b/pkg/sentry/fsimpl/gofer/directory.go index baa2cdd8e..6d4ebc2bf 100644 --- a/pkg/sentry/fsimpl/gofer/directory.go +++ b/pkg/sentry/fsimpl/gofer/directory.go @@ -87,6 +87,10 @@ func (d *dentry) getDirents(ctx context.Context) ([]vfs.Dirent, error) { // to assume that directory fids have the correct semantics, and translates // struct file_operations::readdir calls directly to readdir RPCs), but is // consistent with VFS1. + // + // NOTE(b/135560623): In particular, some gofer implementations may not + // retain state between calls to Readdir, so may not provide a coherent + // directory stream across in the presence of mutation. d.fs.renameMu.RLock() defer d.fs.renameMu.RUnlock() -- cgit v1.2.3