X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f0dfc29c713f1341a33b272aa395db9c36405a83..0bd2681966523df88ad5cf8e505b532843e58d74:/src/common/tokenzr.cpp diff --git a/src/common/tokenzr.cpp b/src/common/tokenzr.cpp index 12aa6c2e1d..8c29cd7cfa 100644 --- a/src/common/tokenzr.cpp +++ b/src/common/tokenzr.cpp @@ -260,10 +260,11 @@ wxString wxStringTokenizer::GetNextToken() { // in wxTOKEN_RET_DELIMS mode we return the delimiter character // with token, otherwise leave it out + wxString::const_iterator tokenEnd(pos); if ( m_mode == wxTOKEN_RET_DELIMS ) - ++pos; + ++tokenEnd; - token.assign(m_pos, pos); + token.assign(m_pos, tokenEnd); // skip the token and the trailing delimiter m_pos = pos + 1;