fix: split command infinite loop
This commit is contained in:
parent
bb6a4ed9c8
commit
cc1e384001
|
@ -1030,23 +1030,23 @@ QStringList splitProcessCommand(const QString &cmd)
|
||||||
case SplitProcessCommandQuoteType::Double:
|
case SplitProcessCommandQuoteType::Double:
|
||||||
quoteType = SplitProcessCommandQuoteType::None;
|
quoteType = SplitProcessCommandQuoteType::None;
|
||||||
break;
|
break;
|
||||||
case SplitProcessCommandQuoteType::Single:
|
default:
|
||||||
break;
|
current+=cmd[i];
|
||||||
}
|
}
|
||||||
current+=cmd[i];
|
i++;
|
||||||
break;
|
break;
|
||||||
case '\'':
|
case '\'':
|
||||||
switch(quoteType) {
|
switch(quoteType) {
|
||||||
case SplitProcessCommandQuoteType::None:
|
case SplitProcessCommandQuoteType::None:
|
||||||
quoteType = SplitProcessCommandQuoteType::Single;
|
quoteType = SplitProcessCommandQuoteType::Single;
|
||||||
break;
|
break;
|
||||||
case SplitProcessCommandQuoteType::Double:
|
|
||||||
break;
|
|
||||||
case SplitProcessCommandQuoteType::Single:
|
case SplitProcessCommandQuoteType::Single:
|
||||||
quoteType = SplitProcessCommandQuoteType::None;
|
quoteType = SplitProcessCommandQuoteType::None;
|
||||||
break;
|
break;
|
||||||
|
default:
|
||||||
|
current+=cmd[i];
|
||||||
}
|
}
|
||||||
current+=cmd[i];
|
i++;
|
||||||
break;
|
break;
|
||||||
case '\\':
|
case '\\':
|
||||||
current += cmd[i];
|
current += cmd[i];
|
||||||
|
|
Loading…
Reference in New Issue