Fix of escape_strings_cstyle(), which did not enclose a single word
string containing semicolon ';' character into quotes.
This commit is contained in:
parent
e20a06a850
commit
e83d89dee7
@ -73,7 +73,7 @@ std::string escape_strings_cstyle(const std::vector<std::string> &strs)
|
||||
bool should_quote = strs.size() == 1 && str.empty();
|
||||
for (size_t i = 0; i < str.size(); ++ i) {
|
||||
char c = str[i];
|
||||
if (c == ' ' || c == '\t' || c == '\\' || c == '"' || c == '\r' || c == '\n') {
|
||||
if (c == ' ' || c == ';' || c == '\t' || c == '\\' || c == '"' || c == '\r' || c == '\n') {
|
||||
should_quote = true;
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user