Zebediah Figura : server: Free the old process image name if a second process image is mapped (Valgrind).
Alexandre Julliard
julliard at winehq.org
Mon Jun 14 16:00:35 CDT 2021
Module: wine
Branch: master
Commit: aa61e519d57d534df51a8b42df6f853c305615a1
URL: https://source.winehq.org/git/wine.git/?a=commit;h=aa61e519d57d534df51a8b42df6f853c305615a1
Author: Zebediah Figura <z.figura12 at gmail.com>
Date: Sat Jun 12 16:42:53 2021 -0500
server: Free the old process image name if a second process image is mapped (Valgrind).
Signed-off-by: Zebediah Figura <z.figura12 at gmail.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
server/mapping.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/server/mapping.c b/server/mapping.c
index 9cb24a4213f..cd918224caa 100644
--- a/server/mapping.c
+++ b/server/mapping.c
@@ -376,6 +376,9 @@ static void add_process_view( struct thread *thread, struct memory_view *view )
/* main exe */
set_process_machine( process, view );
list_add_head( &process->views, &view->entry );
+
+ free( process->image );
+ process->image = NULL;
if (get_view_nt_name( view, &name ) && (process->image = memdup( name.str, name.len )))
process->imagelen = name.len;
return;
More information about the wine-cvs
mailing list