summaryrefslogtreecommitdiffstats
path: root/src/StringUtils.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/StringUtils.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/StringUtils.cpp b/src/StringUtils.cpp
index 47fb6e5a1..95b3c7400 100644
--- a/src/StringUtils.cpp
+++ b/src/StringUtils.cpp
@@ -170,7 +170,12 @@ AStringVector StringSplitWithQuotes(const AString & str, const AString & delim)
{
AString current = str.substr(Prev);
- if ((current.length() >= 2) && ((current.front() == '"') || (current.front() == '\'')) && (current.front() == current.back()))
+ // If the remant is wrapped in matching quotes, remove them:
+ if (
+ (current.length() >= 2) &&
+ ((current.front() == '"') || (current.front() == '\'')) &&
+ (current.front() == current.back())
+ )
{
current = current.substr(1, current.length() - 2);
}