diff --git a/lib/irrlicht/source/Irrlicht/CXMLReaderImpl.h b/lib/irrlicht/source/Irrlicht/CXMLReaderImpl.h index 2b0605640..12a631734 100644 --- a/lib/irrlicht/source/Irrlicht/CXMLReaderImpl.h +++ b/lib/irrlicht/source/Irrlicht/CXMLReaderImpl.h @@ -570,7 +570,7 @@ private: pos = origstr.findNext(L'&', pos); } - if (oldPos < (int)origstr.size()-1) + if ((int)origstr.size()-oldPos > 0) newstr.append(origstr.subString(oldPos, origstr.size()-oldPos)); return newstr;