From 77057674fbe871b6a3eb6fe07084b9288b78571a Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Wed, 6 Mar 2013 12:33:33 +0100 Subject: [PATCH] de-duplicate and accelerate code ... by using existing function. Change-Id: I25e60e70b307885c46b03b6458f06a561976590c Reviewed-by: Thiago Macieira Reviewed-by: Kai Koehne --- src/corelib/global/qlogging.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/corelib/global/qlogging.cpp b/src/corelib/global/qlogging.cpp index ccb09a84d4..13470d9479 100644 --- a/src/corelib/global/qlogging.cpp +++ b/src/corelib/global/qlogging.cpp @@ -171,9 +171,7 @@ static void qEmergencyOut(QtMsgType msgType, const char *msg, va_list ap) Q_DECL fflush(stderr); #endif - if (msgType == QtFatalMsg - || (msgType == QtWarningMsg - && qEnvironmentVariableIsSet("QT_FATAL_WARNINGS"))) { + if (isFatal(msgType)) { #if defined(Q_CC_MSVC) && defined(QT_DEBUG) && defined(_DEBUG) && defined(_CRT_ERROR) // get the current report mode int reportMode = _CrtSetReportMode(_CRT_ERROR, _CRTDBG_MODE_WNDW);