Add leak checking for kernfs.Dentry.

Updates #1486.

PiperOrigin-RevId: 339581879
This commit is contained in:
Dean Deng
2020-10-28 19:02:02 -07:00
committed by gVisor bot
parent 3b4674ffe0
commit 265f1eb2c7
8 changed files with 131 additions and 39 deletions
+1 -1
View File
@@ -113,7 +113,7 @@ func (fstype *FilesystemType) newFilesystem(ctx context.Context, vfsObj *vfs.Vir
root.EnableLeakCheck()
var rootD kernfs.Dentry
rootD.Init(&fs.Filesystem, root)
rootD.InitRoot(&fs.Filesystem, root)
// Construct the pts master inode and dentry. Linux always uses inode
// id 2 for ptmx. See fs/devpts/inode.c:mknod_ptmx.