Backport r65496: Fix infinite loop in wxDateTime::Format() when fields width was used. Closes #12451
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@65724 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -2664,9 +2664,10 @@ wxString wxDateTime::Format(const wxChar *format, const TimeZone& tz) const
|
||||
|
||||
default:
|
||||
// is it the format width?
|
||||
fmt.Empty();
|
||||
while ( *p == _T('-') || *p == _T('+') ||
|
||||
*p == _T(' ') || wxIsdigit(*p) )
|
||||
for( fmt.clear();
|
||||
*p == _T('-') || *p == _T('+') ||
|
||||
*p == _T(' ') || wxIsdigit(*p);
|
||||
++p )
|
||||
{
|
||||
fmt += *p;
|
||||
}
|
||||
|
Reference in New Issue
Block a user