Merge pull request #6742 from taosdata/hotfix/TD-5021

[TD-5021]fix dead loop issue
This commit is contained in:
Haojun Liao 2021-07-05 18:25:21 +08:00 committed by GitHub
commit 95a1c95609
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -954,6 +954,10 @@ static int32_t tscCheckIfCreateTable(char **sqlstr, SSqlObj *pSql, char** boundC
break;
}
if (sToken.n == 0 || sToken.type == TK_SEMI || index == 0) {
return tscSQLSyntaxErrMsg(pCmd->payload, "unexpected token", sql);
}
sql += index;
++numOfColsAfterTags;
}