From 699df74197dddf2feb2d469009e2794e012e9109 Mon Sep 17 00:00:00 2001 From: Marc Mutz Date: Sun, 7 Sep 2014 21:22:04 +0200 Subject: [PATCH] QLibrary: use qEnvironmentVariableIntValue() It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I8d440619edfbd90045564e1f92676f1e1f87e136 Reviewed-by: Thiago Macieira --- src/corelib/plugin/qlibrary.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/corelib/plugin/qlibrary.cpp b/src/corelib/plugin/qlibrary.cpp index 8af38acf51..df6b0a62d6 100644 --- a/src/corelib/plugin/qlibrary.cpp +++ b/src/corelib/plugin/qlibrary.cpp @@ -1131,7 +1131,7 @@ bool qt_debug_component() { static int debug_env = -1; if (debug_env == -1) - debug_env = QT_PREPEND_NAMESPACE(qgetenv)("QT_DEBUG_PLUGINS").toInt(); + debug_env = QT_PREPEND_NAMESPACE(qEnvironmentVariableIntValue)("QT_DEBUG_PLUGINS"); return debug_env != 0; }