From 5e8b11415a8e3241668bc875638346027f25d1b2 Mon Sep 17 00:00:00 2001 From: Hongze Cheng Date: Tue, 21 Jul 2020 18:08:46 +0800 Subject: [PATCH] need to restore magic number when kvstore open --- src/util/src/tkvstore.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/util/src/tkvstore.c b/src/util/src/tkvstore.c index a2022569bf..0704285da5 100644 --- a/src/util/src/tkvstore.c +++ b/src/util/src/tkvstore.c @@ -141,6 +141,7 @@ SKVStore *tdOpenKVStore(char *fname, iterFunc iFunc, afterFunc aFunc, void *appH if (tdLoadKVStoreHeader(pStore->fd, pStore->fname, &info) < 0) goto _err; pStore->info.size = TD_KVSTORE_HEADER_SIZE; + pStore->info.magic = info.magic; if (tdRestoreKVStore(pStore) < 0) goto _err; -- GitLab