Skip to content

SeaweedFS is a distributed storage system for object storage (S3), file systems, Iceberg table buckets, and Lance vector buckets, designed to handle billions of files with O(1) disk access and effortless horizontal scaling.

fix key corrupt when fs.configure copy path trie (#4353)

LHHDZ8e80ce9476c6
diff --git a/weed/filer/filer_conf.go b/weed/filer/filer_conf.go
index b12d54fc80..f3a25242d8 100644
--- a/weed/filer/filer_conf.go
+++ b/weed/filer/filer_conf.go
@@ -125,7 +125,8 @@ func (fc *FilerConf) DeleteLocationConf(locationPrefix string) {
if string(key) == locationPrefix {
return true
}
- rules.Put(key, value)
+ key = bytes.Clone(key)
+ _ = rules.Put(key, value)
return true
})
fc.rules = rules