X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/948c6134e7cd57a0b776b9440975a73ce30d7d03..41933aa5a0de47e845a833127a99f7ae9f3df2ea:/src/html/htmlpars.cpp diff --git a/src/html/htmlpars.cpp b/src/html/htmlpars.cpp index 38c0680c23..ed99a443b6 100644 --- a/src/html/htmlpars.cpp +++ b/src/html/htmlpars.cpp @@ -227,7 +227,7 @@ void wxHtmlParser::CreateDOMSubTree(wxHtmlTag *cur, else { while (i < end_pos && *i != wxT('>')) ++i; - textBeginning = i+1; + textBeginning = i < end_pos ? i+1 : i; } } else ++i; @@ -958,7 +958,7 @@ wxHtmlParser::SkipCommentTag(wxString::const_iterator& start, wxString::const_iterator p = start; // comments begin with "