From 4d579f7f578c723a23cdf1aae691b972ea324883 Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Tue, 2 Jul 2019 21:28:51 -0700 Subject: [PATCH] adjust --- weed/filer2/leveldb2/leveldb2_store.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/weed/filer2/leveldb2/leveldb2_store.go b/weed/filer2/leveldb2/leveldb2_store.go index 20132910e..f1a4bac9e 100644 --- a/weed/filer2/leveldb2/leveldb2_store.go +++ b/weed/filer2/leveldb2/leveldb2_store.go @@ -49,9 +49,9 @@ func (store *LevelDB2Store) initialize(dir string, dbCount int) (err error) { for d := 0 ; d < dbCount; d++ { dbFolder := fmt.Sprintf("%s/%02d", dir, d) os.MkdirAll(dbFolder, 0755) - db, err := leveldb.OpenFile(dbFolder, opts) - if err != nil { - glog.Errorf("filer store open dir %s: %v", dbFolder, err) + db, dbErr := leveldb.OpenFile(dbFolder, opts) + if dbErr != nil { + glog.Errorf("filer store open dir %s: %v", dbFolder, dbErr) return } store.dbs = append(store.dbs, db)