X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/1cdaa5f25111febb2959f6673378de99af47c8e4..a3b7db872925df2921f36637a84085ec04cf977a:/src/common/log.cpp diff --git a/src/common/log.cpp b/src/common/log.cpp index 53ce213b50..376a93365b 100644 --- a/src/common/log.cpp +++ b/src/common/log.cpp @@ -856,8 +856,10 @@ wxLogStderr::wxLogStderr(FILE *fp) void wxLogStderr::DoLogText(const wxString& msg) { - wxFputs(msg + '\n', m_fp); - fflush(m_fp); + // First send it to stderr, even if we don't have it (e.g. in a Windows GUI + // application under) it's not a problem to try to use it and it's easier + // than determining whether we do have it or not. + wxMessageOutputStderr(m_fp).Output(msg); // under GUI systems such as Windows or Mac, programs usually don't have // stderr at all, so show the messages also somewhere else, typically in