mount2: dir read opened file

This commit is contained in:
chrislu
2022-02-24 00:37:57 -08:00
parent 320637dc7a
commit b93d57da31
2 changed files with 9 additions and 0 deletions

View File

@@ -176,6 +176,10 @@ func (wfs *WFS) doReadDirectory(input *fuse.ReadIn, out *fuse.DirEntryList, isPl
isEarlyTerminated = true
return false
}
if fh, found := wfs.fhmap.FindFileHandle(inode); found {
glog.V(4).Infof("readdir opened file %s", dirPath.Child(dirEntry.Name))
entry = filer.FromPbEntry(string(dirPath), fh.entry)
}
wfs.outputFilerEntry(entryOut, inode, entry)
}
dh.lastEntryName = entry.Name()