git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@6036
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
const wxChar *pEnd = pStart;
const wxChar *pEnd = pStart;
- while ( *pEnd != wxT('=') && !wxIsspace(*pEnd) ) {
+ while ( *pEnd && *pEnd != wxT('=') && !wxIsspace(*pEnd) ) {
if ( *pEnd == wxT('\\') ) {
// next character may be space or not - still take it because it's
if ( *pEnd == wxT('\\') ) {
// next character may be space or not - still take it because it's
+ // quoted (unless there is nothing)
+ if ( !*pEnd ) {
+ // the error message will be given below anyhow
+ break;
+ }
- wxString strKey(FilterInEntryName(wxString(pStart, count)));
+ wxString strKey(FilterInEntryName(wxString(pStart, pEnd)));
// skip whitespace
while ( isspace(*pEnd) )
// skip whitespace
while ( isspace(*pEnd) )