X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/cf9f6737895ace461dcc8ce55ba56bebb97c6a4b..1372f8ccd05daece34d4f44a07f95f45aee967de:/src/common/datetime.cpp diff --git a/src/common/datetime.cpp b/src/common/datetime.cpp index f6ad3f6259..8bd4933a18 100644 --- a/src/common/datetime.cpp +++ b/src/common/datetime.cpp @@ -487,8 +487,10 @@ static wxString CallStrftime(const wxString& format, const tm* tm) if ( !wxStrftime(buf, WXSIZEOF(buf), format, tm) ) { - // buffer is too small? + // if the format is valid, buffer must be too small? wxFAIL_MSG(_T("strftime() failed")); + + buf[0] = '\0'; } s = buf;