X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/4e2c2c7062f7cf92b61d8a474a94dee05de70760..68893d580363f62c7579cade2d9ee8f954eaf309:/src/common/datetimefmt.cpp diff --git a/src/common/datetimefmt.cpp b/src/common/datetimefmt.cpp index cd4cb83974..f9404d8642 100644 --- a/src/common/datetimefmt.cpp +++ b/src/common/datetimefmt.cpp @@ -1559,7 +1559,7 @@ wxDateTime::ParseDate(const wxString& date, wxString::const_iterator *end) const wxString::const_iterator pEnd = date.end(); wxString::const_iterator p = pBegin; - while ( wxIsspace(*p) ) + while ( p != pEnd && wxIsspace(*p) ) p++; // some special cases @@ -1941,7 +1941,7 @@ wxDateTime::ParseTime(const wxString& time, wxString::const_iterator *end) "%I:%M:%S %p", // 12hour with AM/PM "%H:%M:%S", // could be the same or 24 hour one so try it too "%I:%M %p", // 12hour with AM/PM but without seconds - "%H:%M:%S", // and a possibly 24 hour version without seconds + "%H:%M", // and a possibly 24 hour version without seconds "%X", // possibly something from above or maybe something // completely different -- try it last