From 0167cca26983f082f755a3cb71df1567fb327851 Mon Sep 17 00:00:00 2001 From: Hongze Cheng Date: Tue, 24 Nov 2020 10:49:05 +0000 Subject: [PATCH] refact --- src/tsdb/src/tsdbFile.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tsdb/src/tsdbFile.c b/src/tsdb/src/tsdbFile.c index a6db0ebbf1..a2be57eb7e 100644 --- a/src/tsdb/src/tsdbFile.c +++ b/src/tsdb/src/tsdbFile.c @@ -155,8 +155,8 @@ void tsdbRemoveFileGroup(STsdbRepo *pRepo, SFileGroup *pFGroup) { } SFileGroup *tsdbSearchFGroup(STsdbFileH *pFileH, int fid, int flags) { - void *ptr - taosbsearch((void *)(&fid), (void *)(pFileH->pFGroup), pFileH->nFGroups, sizeof(SFileGroup), keyFGroupCompFunc, flags); + void *ptr = taosbsearch((void *)(&fid), (void *)(pFileH->pFGroup), pFileH->nFGroups, sizeof(SFileGroup), + keyFGroupCompFunc, flags); if (ptr == NULL) return NULL; return (SFileGroup *)ptr; } -- GitLab