From 68e15819a1d7ecf7c5df6d7f7b47aad9fed94508 Mon Sep 17 00:00:00 2001 From: Cary Xu Date: Wed, 15 Sep 2021 06:58:56 +0800 Subject: [PATCH] type convert --- src/tsdb/src/tsdbFS.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tsdb/src/tsdbFS.c b/src/tsdb/src/tsdbFS.c index 1578067067..7f26f06fff 100644 --- a/src/tsdb/src/tsdbFS.c +++ b/src/tsdb/src/tsdbFS.c @@ -102,8 +102,8 @@ static int tsdbDecodeDFileSetArray(void **originBuf, void *buf, SArray *pArray, if (pSFSHeader->version == TSDB_FS_VER_0) { uint64_t extendedSize = pSFSHeader->len + nset * TSDB_FILE_MAX * sizeof(TSDB_FVER_TYPE); if (taosTSizeof(*originBuf) < extendedSize) { - size_t ptrDistance = (size_t)POINTER_DISTANCE(buf, *originBuf); - if (tsdbMakeRoom(originBuf, extendedSize) < 0) { + size_t ptrDistance = POINTER_DISTANCE(buf, *originBuf); + if (tsdbMakeRoom(originBuf, (size_t)extendedSize) < 0) { terrno = TSDB_CODE_FS_OUT_OF_MEMORY; return -1; } -- GitLab