提交 a0ae611a 编写于 作者: A Alex Duan

fix: fix can not scroll enum item with blank

上级 4976c80e
......@@ -536,7 +536,7 @@ SWord* addWord(const char* p, int32_t len, bool pattern) {
word->len = len;
// check format
if (pattern) {
if (pattern && len > 0) {
word->type = wordType(p, len);
} else {
word->type = WT_TEXT;
......@@ -577,11 +577,8 @@ void parseCommand(SWords* command, bool pattern) {
while (word->next) {
word = word->next;
}
int len = i - start;
if (len > 0) {
word->next = addWord(p + start, len, pattern);
command->count++;
}
word->next = addWord(p + start, i - start, pattern);
command->count++;
}
start = i + 1;
} else {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册