diff options
author | gVisor bot <gvisor-bot@google.com> | 2020-08-06 01:19:56 +0000 |
---|---|---|
committer | gVisor bot <gvisor-bot@google.com> | 2020-08-06 01:19:56 +0000 |
commit | 223374a244992c635fde3e326e7e96f5bcd0e545 (patch) | |
tree | 532056a914add7ec15981432dfe0807778a6dc5e /pkg/sentry | |
parent | c602ce3ae7a7aaaad777b8c22923993dbebaf7e3 (diff) | |
parent | 7ed4b2b5a6928b3a4a88d0117a764dd4795be61a (diff) |
Merge release-20200804.0-26-g7ed4b2b5a (automated)
Diffstat (limited to 'pkg/sentry')
-rw-r--r-- | pkg/sentry/fsimpl/tmpfs/filesystem.go | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/pkg/sentry/fsimpl/tmpfs/filesystem.go b/pkg/sentry/fsimpl/tmpfs/filesystem.go index fb77f95cc..065812065 100644 --- a/pkg/sentry/fsimpl/tmpfs/filesystem.go +++ b/pkg/sentry/fsimpl/tmpfs/filesystem.go @@ -566,7 +566,9 @@ func (fs *filesystem) RenameAt(ctx context.Context, rp *vfs.ResolvingPath, oldPa if replaced != nil { newParentDir.removeChildLocked(replaced) if replaced.inode.isDir() { - newParentDir.inode.decLinksLocked(ctx) // from replaced's ".." + // Remove links for replaced/. and replaced/.. + replaced.inode.decLinksLocked(ctx) + newParentDir.inode.decLinksLocked(ctx) } replaced.inode.decLinksLocked(ctx) } |