Remove uses of qMalloc/qFree from out of line code.
authorRobin Burchell <robin.burchell@collabora.com>
Sat, 21 Jan 2012 14:09:51 +0000 (16:09 +0200)
committerQt by Nokia <qt-info@nokia.com>
Mon, 23 Jan 2012 11:49:55 +0000 (12:49 +0100)
There is no need to use these, and we are trying to deprecate them.

Change-Id: I70e6f27aca322fe74c31d8ad8496f230cd29e503
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
src/corelib/io/qfilesystemengine_win.cpp

index cbf8996..a9faa9f 100644 (file)
@@ -180,7 +180,7 @@ public:
 
 SidCleanup::~SidCleanup()
 {
-    qFree(currentUserSID);
+    free(currentUserSID);
     currentUserSID = 0;
 
     // worldSID was allocated with AllocateAndInitializeSid so it needs to be freed with FreeSid
@@ -232,15 +232,15 @@ static void resolveLibs()
                 // doing a dummy GetTokenInformation call.
                 ::GetTokenInformation(token, TokenUser, 0, 0, &retsize);
                 if (retsize) {
-                    void *tokenBuffer = qMalloc(retsize);
+                    void *tokenBuffer = malloc(retsize);
                     if (::GetTokenInformation(token, TokenUser, tokenBuffer, retsize, &retsize)) {
                         PSID tokenSid = reinterpret_cast<PTOKEN_USER>(tokenBuffer)->User.Sid;
                         DWORD sidLen = ::GetLengthSid(tokenSid);
-                        currentUserSID = reinterpret_cast<PSID>(qMalloc(sidLen));
+                        currentUserSID = reinterpret_cast<PSID>(malloc(sidLen));
                         if (::CopySid(sidLen, currentUserSID, tokenSid))
                             ptrBuildTrusteeWithSidW(&currentUserTrusteeW, currentUserSID);
                     }
-                    qFree(tokenBuffer);
+                    free(tokenBuffer);
                 }
                 ::CloseHandle(token);
             }