diff --git a/src/util/src/tcrc32c.c b/src/util/src/tcrc32c.c
index 3ef10b1b0d..502116f9c2 100644
--- a/src/util/src/tcrc32c.c
+++ b/src/util/src/tcrc32c.c
@@ -1353,12 +1353,12 @@ uint32_t crc32c_hw(uint32_t crc, crc_stream buf, size_t len) {
#endif // #ifndef _TD_ARM_
void taosResolveCRC() {
-#ifndef _TD_ARM_
+#if defined _TD_ARM_ || defined WINDOWS
+ crc32c = crc32c_sf;
+#else
int sse42;
SSE42(sse42);
crc32c = sse42 ? crc32c_hw : crc32c_sf;
-#else
- crc32c = crc32c_sf;
#endif
/* return sse42 ? crc32c_hw(crci, bytes, len) : crc32c_sf(crci, bytes, len);
*/
diff --git a/src/util/src/tkvstore.c b/src/util/src/tkvstore.c
index 1000b96a31..bd0d71f963 100644
--- a/src/util/src/tkvstore.c
+++ b/src/util/src/tkvstore.c
@@ -522,7 +522,7 @@ static int tdRestoreKVStore(SKVStore *pStore) {
maxBufSize = MAX(maxBufSize, rInfo.size);
- if (lseek(pStore->fd, rInfo.size, SEEK_CUR) < 0) {
+ if (lseek(pStore->fd, (off_t)rInfo.size, SEEK_CUR) < 0) {
uError("failed to lseek file %s since %s", pStore->fname, strerror(errno));
terrno = TAOS_SYSTEM_ERROR(errno);
goto _err;
@@ -550,7 +550,7 @@ static int tdRestoreKVStore(SKVStore *pStore) {
while (taosHashIterNext(pIter)) {
SKVRecord *pRecord = taosHashIterGet(pIter);
- if (lseek(pStore->fd, pRecord->offset + sizeof(SKVRecord), SEEK_SET) < 0) {
+ if (lseek(pStore->fd, (off_t)(pRecord->offset + sizeof(SKVRecord)), SEEK_SET) < 0) {
uError("failed to lseek file %s since %s, offset %" PRId64, pStore->fname, strerror(errno), pRecord->offset);
terrno = TAOS_SYSTEM_ERROR(errno);
goto _err;
diff --git a/src/util/src/tmempool.c b/src/util/src/tmempool.c
index 4a899ebb48..a3d1035500 100644
--- a/src/util/src/tmempool.c
+++ b/src/util/src/tmempool.c
@@ -13,11 +13,7 @@
* along with this program. If not, see .
*/
-#include
-#include
-#include
-#include
-
+#include "os.h"
#include "tulog.h"
#include "tmempool.h"
#include "tutil.h"