fix(query): fix syntax errors on centos.

This commit is contained in:
Haojun Liao 2023-02-24 11:42:08 +08:00
parent 22aa03307c
commit 8eb1e56e8d
1 changed files with 2 additions and 2 deletions

View File

@ -319,8 +319,8 @@ void *taosStrdup(const char *ptr) {
TdMemoryInfoPtr pTdMemoryInfo = (TdMemoryInfoPtr)((char *)ptr - sizeof(TdMemoryInfo)); TdMemoryInfoPtr pTdMemoryInfo = (TdMemoryInfoPtr)((char *)ptr - sizeof(TdMemoryInfo));
ASSERT(pTdMemoryInfo->symbol == TD_MEMORY_SYMBOL); ASSERT(pTdMemoryInfo->symbol == TD_MEMORY_SYMBOL);
if (pTdMemoryInfo->symbol != TD_MEMORY_SYMBOL) { if (pTdMemoryInfo->symbol != TD_MEMORY_SYMBOL) {
+ return NULL; return NULL;
+ } }
void *tmp = tstrdup(pTdMemoryInfo); void *tmp = tstrdup(pTdMemoryInfo);
if (tmp == NULL) return NULL; if (tmp == NULL) return NULL;