1
0
Fork 0

Fixed some markup issues

This commit is contained in:
flx5 2015-03-11 04:38:15 +01:00
parent 451ab6860f
commit 76012ee090
1 changed files with 4 additions and 3 deletions

View File

@ -150,11 +150,11 @@ AStringVector StringSplitWithQuotes(const AString & str, const AString & delim)
while ((cutAt = str.find_first_of(delim, Prev)) != str.npos)
{
AString current = str.substr(Prev, cutAt - Prev);
if ((current.at(0) == '"') || (current.at(0) == '\''))
if ((current.at(0) == '"') || (current.at(0) == '\''))
{
Prev += 1;
cutAt = str.find_first_of(current.at(0), Prev);
if (cutAt != str.npos)
if (cutAt != str.npos)
{
current = str.substr(Prev, cutAt - Prev);
cutAt += 1;
@ -169,7 +169,8 @@ 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 ((current.length() >= 2) && ((current.front() == '"') || (current.front() == '\'')) && (current.front() == current.back()))
{
current = current.substr(1, current.length() - 2);
}