Mercurial > hg > svcore
diff base/StringBits.cpp @ 1019:a73c44ae5acb
Fix close-quote immediately before separator in StringBits::splitQuoted
author | Chris Cannam |
---|---|
date | Thu, 27 Nov 2014 17:50:34 +0000 |
parents | 6a94bb528e9d |
children | eecf544bed92 |
line wrap: on
line diff
--- a/base/StringBits.cpp Thu Nov 20 12:30:16 2014 +0000 +++ b/base/StringBits.cpp Thu Nov 27 17:50:34 2014 +0000 @@ -83,14 +83,14 @@ switch (mode) { case sep: mode = q1; break; case unq: case q2: tok += c; break; - case q1: mode = sep; tokens << tok; tok = ""; break; + case q1: mode = unq; break; } } else if (c == '"') { switch (mode) { case sep: mode = q2; break; case unq: case q1: tok += c; break; - case q2: mode = sep; tokens << tok; tok = ""; break; + case q2: mode = unq; break; } } else if (c == separator || (separator == ' ' && c.isSpace())) {