diff options
| author | Chris Lu <chris.lu@gmail.com> | 2018-12-02 23:16:17 -0800 |
|---|---|---|
| committer | Chris Lu <chris.lu@gmail.com> | 2018-12-02 23:16:17 -0800 |
| commit | c6b646e92c11e705f65d2513e9925f78f6a1bbfa (patch) | |
| tree | e8c946cbc145692e522580e203ce06168a0ca079 | |
| parent | bea162c34c846dcaa79b76afd98d2f700694f971 (diff) | |
| download | seaweedfs-c6b646e92c11e705f65d2513e9925f78f6a1bbfa.tar.xz seaweedfs-c6b646e92c11e705f65d2513e9925f78f6a1bbfa.zip | |
skip creation for root
| -rw-r--r-- | weed/filer2/filer.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/weed/filer2/filer.go b/weed/filer2/filer.go index 486f7eaaf..d49c86a76 100644 --- a/weed/filer2/filer.go +++ b/weed/filer2/filer.go @@ -56,6 +56,10 @@ func (fs *Filer) KeepConnectedToMaster() { func (f *Filer) CreateEntry(entry *Entry) error { + if string(entry.FullPath) == "/" { + return nil + } + dirParts := strings.Split(string(entry.FullPath), "/") // fmt.Printf("directory parts: %+v\n", dirParts) |
