diff --git a/libgnucash/engine/gnc-datetime.cpp b/libgnucash/engine/gnc-datetime.cpp index cbacd3d2a3..c648a51d2d 100644 --- a/libgnucash/engine/gnc-datetime.cpp +++ b/libgnucash/engine/gnc-datetime.cpp @@ -535,11 +535,14 @@ constexpr size_t DATEBUFLEN = 100; static std::string win_date_format(std::string format, struct tm tm) { +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wdeprecated-declarations" wchar_t buf[DATEBUFLEN]; memset(buf, 0, DATEBUFLEN); std::wstring_convert, wchar_t> conv; auto numchars = wcsftime(buf, DATEBUFLEN - 1, conv.from_bytes(format).c_str(), &tm); return conv.to_bytes(buf); +#pragma GCC diagnostic pop } /* Microsoft's strftime uses the time zone flags differently from