aboutsummaryrefslogtreecommitdiff
path: root/weed/filesys/xattr.go
diff options
context:
space:
mode:
Diffstat (limited to 'weed/filesys/xattr.go')
-rw-r--r--weed/filesys/xattr.go9
1 files changed, 3 insertions, 6 deletions
diff --git a/weed/filesys/xattr.go b/weed/filesys/xattr.go
index 3ccecdf98..993e7ad93 100644
--- a/weed/filesys/xattr.go
+++ b/weed/filesys/xattr.go
@@ -1,9 +1,6 @@
package filesys
import (
- "context"
- "strings"
-
"github.com/chrislusf/seaweedfs/weed/filer2"
"github.com/chrislusf/seaweedfs/weed/glog"
"github.com/chrislusf/seaweedfs/weed/pb/filer_pb"
@@ -124,9 +121,9 @@ func (wfs *WFS) maybeLoadEntry(dir, name string) (entry *filer_pb.Entry, err err
Directory: dir,
}
- resp, err := client.LookupDirectoryEntry(context.Background(), request)
- if err != nil || resp == nil || resp.Entry == nil {
- if err == filer2.ErrNotFound || strings.Contains(err.Error(), filer2.ErrNotFound.Error()) {
+ resp, err := filer_pb.LookupEntry(client, request)
+ if err != nil {
+ if err == filer2.ErrNotFound {
glog.V(3).Infof("file attr read not found file %v: %v", request, err)
return fuse.ENOENT
}