From ade43d4bc4240ead5d641ae84a1ff37f60d19c9c Mon Sep 17 00:00:00 2001 From: David Faure Date: Fri, 3 Aug 2012 12:30:59 +0200 Subject: Fix valgrind errors due to "const char *getSystemLocale" qgetenv returns a QByteArray, so casting that to a char* leads to using deleted memory. This was introduced by 25c4ce6deef20c69d00fe1197a60e8b7587c81cb. Change-Id: I27ccad022e327e119fea3c3cdcf9beb541ab9097 Reviewed-by: Thiago Macieira Reviewed-by: Nick Ratelle --- src/corelib/tools/qlocale_unix.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/corelib/tools/qlocale_unix.cpp b/src/corelib/tools/qlocale_unix.cpp index e702ecf..4a5689c 100644 --- a/src/corelib/tools/qlocale_unix.cpp +++ b/src/corelib/tools/qlocale_unix.cpp @@ -52,7 +52,7 @@ QT_BEGIN_NAMESPACE -static const char *getSystemLocale() +static QByteArray getSystemLocale() { #if defined(Q_OS_QNX) static char buff[257]; -- cgit v0.12