Sven Baars : kernelbase: Fix a string leak in CreateProcessInternal (Valgrind).

Alexandre Julliard julliard at winehq.org
Fri Aug 7 10:42:30 CDT 2020


Module: wine
Branch: stable
Commit: 3e0050f840e8f78826c9ffe5d3231b5075fbb6f3
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=3e0050f840e8f78826c9ffe5d3231b5075fbb6f3

Author: Sven Baars <sbaars at codeweavers.com>
Date:   Sat Apr 18 22:06:46 2020 +0200

kernelbase: Fix a string leak in CreateProcessInternal (Valgrind).

Signed-off-by: Sven Baars <sbaars at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
(cherry picked from commit a202ecd457d7b13a0534398ca0227e78ad77f7b0)
Signed-off-by: Michael Stefaniuc <mstefani at winehq.org>

---

 dlls/kernelbase/process.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/dlls/kernelbase/process.c b/dlls/kernelbase/process.c
index 3cd2934c20..4694be0306 100644
--- a/dlls/kernelbase/process.c
+++ b/dlls/kernelbase/process.c
@@ -182,10 +182,12 @@ static RTL_USER_PROCESS_PARAMETERS *create_process_params( const WCHAR *filename
                                       &cmdlineW, envW, &titleW, &desktopW,
                                       NULL, &runtimeW, PROCESS_PARAMS_FLAG_NORMALIZED ))
     {
+        RtlFreeUnicodeString( &newdirW );
         RtlReleasePath( load_path );
         if (envW != env) RtlFreeHeap( GetProcessHeap(), 0, envW );
         return NULL;
     }
+    RtlFreeUnicodeString( &newdirW );
     RtlReleasePath( load_path );
 
     if (flags & CREATE_NEW_PROCESS_GROUP) params->ConsoleFlags = 1;




More information about the wine-cvs mailing list