Michael Stefaniuc : msi: Remove redundant NULL checks before msi_free().

Alexandre Julliard julliard at winehq.org
Wed Sep 20 15:10:23 CDT 2017


Module: wine
Branch: master
Commit: 4a2809166c4056a73956093f341125f4c3c07f4f
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=4a2809166c4056a73956093f341125f4c3c07f4f

Author: Michael Stefaniuc <mstefani at winehq.org>
Date:   Wed Sep 20 12:28:00 2017 +0200

msi: Remove redundant NULL checks before msi_free().

Signed-off-by: Michael Stefaniuc <mstefani at winehq.org>
Signed-off-by: Hans Leidekker <hans at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/msi/dialog.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/dlls/msi/dialog.c b/dlls/msi/dialog.c
index 2ccaf62..bc41403 100644
--- a/dlls/msi/dialog.c
+++ b/dlls/msi/dialog.c
@@ -4309,7 +4309,7 @@ static UINT event_end_dialog( msi_dialog *dialog, const WCHAR *argument )
 static UINT pending_event_end_dialog( msi_dialog *dialog, const WCHAR *argument )
 {
     dialog->pending_event = event_end_dialog;
-    if (dialog->pending_argument) msi_free( dialog->pending_argument );
+    msi_free( dialog->pending_argument );
     dialog->pending_argument = strdupW( argument );
     return ERROR_SUCCESS;
 }
@@ -4327,7 +4327,7 @@ static UINT event_new_dialog( msi_dialog *dialog, const WCHAR *argument )
 static UINT pending_event_new_dialog( msi_dialog *dialog, const WCHAR *argument )
 {
     dialog->pending_event = event_new_dialog;
-    if (dialog->pending_argument) msi_free( dialog->pending_argument );
+    msi_free( dialog->pending_argument );
     dialog->pending_argument = strdupW( argument );
     return ERROR_SUCCESS;
 }
@@ -4352,7 +4352,7 @@ static UINT event_spawn_dialog( msi_dialog *dialog, const WCHAR *argument )
 static UINT pending_event_spawn_dialog( msi_dialog *dialog, const WCHAR *argument )
 {
     dialog->pending_event = event_spawn_dialog;
-    if (dialog->pending_argument) msi_free( dialog->pending_argument );
+    msi_free( dialog->pending_argument );
     dialog->pending_argument = strdupW( argument );
     return ERROR_SUCCESS;
 }




More information about the wine-cvs mailing list