diff options
| author | Chris Lu <chris.lu@gmail.com> | 2018-05-19 12:40:24 -0700 |
|---|---|---|
| committer | Chris Lu <chris.lu@gmail.com> | 2018-05-19 12:40:24 -0700 |
| commit | 793dd81ca2c81f4dab1cf65bb45ccb1e5726a54d (patch) | |
| tree | 18ab4f229487aa927b01b69e01d9c67ffc9beac2 /weed/filer2/filer.go | |
| parent | ab4ddb1e0ee425d0d779eb529c42dc5361320822 (diff) | |
| download | seaweedfs-793dd81ca2c81f4dab1cf65bb45ccb1e5726a54d.tar.xz seaweedfs-793dd81ca2c81f4dab1cf65bb45ccb1e5726a54d.zip | |
skip permission checking when creating dir or files
Diffstat (limited to 'weed/filer2/filer.go')
| -rw-r--r-- | weed/filer2/filer.go | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/weed/filer2/filer.go b/weed/filer2/filer.go index 467f846ed..2d5920cd8 100644 --- a/weed/filer2/filer.go +++ b/weed/filer2/filer.go @@ -56,7 +56,7 @@ func (f *Filer) CreateEntry(entry *Entry) (error) { if dirFindErr != nil { return fmt.Errorf("findDirectory %s: %v", dirPath, dirFindErr) } - }else{ + } else { glog.V(4).Infof("found cached directory: %s", dirPath) } @@ -98,9 +98,13 @@ func (f *Filer) CreateEntry(entry *Entry) (error) { return fmt.Errorf("parent folder not found: %v", entry.FullPath) } + /* if !hasWritePermission(lastDirectoryEntry, entry) { + glog.V(0).Infof("directory %s: %v, entry: uid=%d gid=%d", + lastDirectoryEntry.FullPath, lastDirectoryEntry.Attr, entry.Uid, entry.Gid) return fmt.Errorf("no write permission in folder %v", lastDirectoryEntry.FullPath) } + */ if err := f.store.InsertEntry(entry); err != nil { return fmt.Errorf("insert entry %s: %v", entry.FullPath, err) |
