remove nodemap, fix directory listing cache

This commit is contained in:
Chris Lu
2018-06-06 22:48:51 -07:00
parent 5c25d29272
commit daabdfe357
2 changed files with 16 additions and 34 deletions

View File

@@ -34,7 +34,7 @@ func (file *File) Attr(ctx context.Context, attr *fuse.Attr) error {
if file.attributes == nil || !file.isOpen {
item := file.wfs.listDirectoryEntriesCache.Get(file.fullpath())
if item != nil {
if item != nil && !item.Expired(){
entry := item.Value().(*filer_pb.Entry)
file.Chunks = entry.Chunks
file.attributes = entry.Attributes