From ccd2064ae8e6c243781c7b221a3216f8e90a653c Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sat, 9 Jan 2021 17:21:02 +0100 Subject: [PATCH] Remove unnecessary use of __WXFUNCTION__ from wxLog code Just micro cleanup: there doesn't seem to be any need to show which function we're in as FormatMessage() is only called from a single place anyhow, so shorten and simplify the code. --- src/common/log.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/common/log.cpp b/src/common/log.cpp index 0084d0033b..968f871ea9 100644 --- a/src/common/log.cpp +++ b/src/common/log.cpp @@ -1076,8 +1076,8 @@ static const wxChar* GetSysErrorMsg(wxChar* szBuf, size_t sizeBuf, unsigned long NULL ) == 0 ) { - wxLogDebug(wxS("FormatMessage failed with error 0x%lx in %s"), - GetLastError(), __WXFUNCTION__ ? __WXFUNCTION__ : ""); + wxLogDebug(wxS("FormatMessage failed with error 0x%lx"), GetLastError()); + // if this happens, something is seriously wrong, so don't use _() here // for safety wxSprintf(szBuf, wxS("unknown error 0x%lx"), nErrCode);