diff --git a/src/util/src/ttokenizer.c b/src/util/src/ttokenizer.c index 3448e8e2baecbafb5e34febf9c2135424e0cccb6..b02ba96f0720bf730190f2408ecd2466225440be 100644 --- a/src/util/src/ttokenizer.c +++ b/src/util/src/ttokenizer.c @@ -275,6 +275,10 @@ static int32_t tKeywordCode(const char* z, int n) { } } + if (keywordHashTable == NULL) { + return TK_ILLEGAL; + } + SKeyword** pKey = (SKeyword**)taosHashGet(keywordHashTable, key, n); return (pKey != NULL)? (*pKey)->type:TK_ID; }