aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorlash <dev@holbrook.no>2018-07-18 15:56:04 +0800
committerAnton Evangelatov <anton.evangelatov@gmail.com>2018-07-23 21:31:02 +0800
commitf5b128a5b3e2105fbaffa19e27031bda29686e0b (patch)
tree2b08fa67a8c87839cd39e386082eeae300b5894c
parentfd982d3f3b32de61dafc32322de23350bf35b6e3 (diff)
downloaddexon-f5b128a5b3e2105fbaffa19e27031bda29686e0b.tar.gz
dexon-f5b128a5b3e2105fbaffa19e27031bda29686e0b.tar.zst
dexon-f5b128a5b3e2105fbaffa19e27031bda29686e0b.zip
swarm/fuse: Hotfix missing parantheses in statement
-rw-r--r--swarm/fuse/swarmfs_unix.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/swarm/fuse/swarmfs_unix.go b/swarm/fuse/swarmfs_unix.go
index 7a913b0de..9ff55cc32 100644
--- a/swarm/fuse/swarmfs_unix.go
+++ b/swarm/fuse/swarmfs_unix.go
@@ -120,6 +120,10 @@ func (swarmfs *SwarmFS) Mount(mhash, mountpoint string) (*MountInfo, error) {
log.Trace("swarmfs mount: traversing manifest map")
for suffix, entry := range manifestEntryMap {
+ if suffix == "" { //empty suffix means that the file has no name - i.e. this is the default entry in a manifest. Since we cannot have files without a name, let us ignore this entry
+ log.Warn("Manifest has an empty-path (default) entry which will be ignored in FUSE mount.")
+ continue
+ }
addr := common.Hex2Bytes(entry.Hash)
fullpath := "/" + suffix
basepath := filepath.Dir(fullpath)