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.

Check for history file errors as well

Daniel Nagy7ce3bee0c005
diff --git a/weed/shell/shell_liner.go b/weed/shell/shell_liner.go
index 38b74bc548..765b0efda9 100644
--- a/weed/shell/shell_liner.go
+++ b/weed/shell/shell_liner.go
@@ -148,9 +148,11 @@ func loadHistory() {
func saveHistory() {
if f, err := os.Create(historyPath); err != nil {
- fmt.Printf("Error writing history file: %v\n", err)
+ fmt.Printf("Error creating history file: %v\n", err)
} else {
- line.WriteHistory(f)
+ if _, err = line.WriteHistory(f); err != nil {
+ fmt.Printf("Error writing history file: %v\n", err)
+ }
f.Close()
}
}