diff --git a/src/common/dcbase.cpp b/src/common/dcbase.cpp index f42c88530e..67f907abca 100644 --- a/src/common/dcbase.cpp +++ b/src/common/dcbase.cpp @@ -2302,7 +2302,7 @@ void wxDCBase::DrawLabel(const wxString& text, wxString curLine; for ( wxString::const_iterator pc = text.begin(); ; ++pc ) { - if ( *pc == _T('\n') || pc == text.end() ) + if ( pc == text.end() || *pc == _T('\n') ) { int xRealStart = x; // init it here to avoid compielr warnings diff --git a/src/html/winpars.cpp b/src/html/winpars.cpp index 229bdac946..1769f56c26 100644 --- a/src/html/winpars.cpp +++ b/src/html/winpars.cpp @@ -379,7 +379,7 @@ void wxHtmlWinParser::AddText(const wxString& txt) ++i, ++x; while ( (i < end) && (*i == wxT('\n') || *i == wxT('\r') || - *i == wxT(' ')) || *i == wxT('\t') ) + *i == wxT(' ') || *i == wxT('\t')) ) { ++i; ++x;