Skip to content

Commit 6448dbe

Browse files
avagingvisor-bot
authored andcommitted
procfs: release the file system mutex on the error path
Reported-by: [email protected] PiperOrigin-RevId: 808759083
1 parent 2925932 commit 6448dbe

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

pkg/sentry/fsimpl/kernfs/filesystem.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -530,6 +530,7 @@ func (fs *Filesystem) OpenAt(ctx context.Context, rp *vfs.ResolvingPath, opts vf
530530
}
531531
if trunc && d.isRegular() {
532532
if err := mnt.CheckBeginWrite(); err != nil {
533+
fs.mu.RUnlock()
533534
return nil, err
534535
}
535536
defer mnt.EndWrite()

0 commit comments

Comments
 (0)