Commit 21296456 authored by Volodymyr Yurchenko's avatar Volodymyr Yurchenko
Browse files

Fail the command if it has odd number of quotes

parent 429e33cd
......@@ -203,6 +203,10 @@ TGridResult *TJAlien::Command(const char *command, bool interactive, UInt_t stre
else {
opt = Strip(token->GetString().Data(), '\"');
append = true;
if (i == tokens->GetEntries() - 1) {
Error("Command", "Invalid command. Check if you miss a matching quote");
return nullptr;
}
continue;
}
}
......@@ -211,6 +215,10 @@ TGridResult *TJAlien::Command(const char *command, bool interactive, UInt_t stre
if (append) {
opt.Append(" ");
opt.Append(token->GetString().Data());
if (i == tokens->GetEntries() - 1) {
Error("Command", "Invalid command. Check if you miss a matching quote");
return nullptr;
}
continue;
}
else
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment