[PATCH 3/3] regedit: Process the next file, if any, on error
Hugh McMaster
hugh.mcmaster at outlook.com
Tue Jul 5 00:15:45 CDT 2016
Signed-off-by: Hugh McMaster <hugh.mcmaster at outlook.com>
---
programs/regedit/regedit.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/programs/regedit/regedit.c b/programs/regedit/regedit.c
index 04dd317..e80aa07 100644
--- a/programs/regedit/regedit.c
+++ b/programs/regedit/regedit.c
@@ -88,7 +88,7 @@ typedef enum {
ACTION_ADD, ACTION_EXPORT, ACTION_DELETE
} REGEDIT_ACTION;
-static BOOL PerformRegAction(REGEDIT_ACTION action, WCHAR **argv, int *i)
+static void PerformRegAction(REGEDIT_ACTION action, WCHAR **argv, int *i)
{
switch (action) {
case ACTION_ADD: {
@@ -113,7 +113,7 @@ static BOOL PerformRegAction(REGEDIT_ACTION action, WCHAR **argv, int *i)
if (size == 0)
{
output_message(STRING_FILE_NOT_FOUND, filename);
- exit(1);
+ return;
}
reg_file = _wfopen(realname, rb_mode);
if (reg_file == NULL)
@@ -121,7 +121,7 @@ static BOOL PerformRegAction(REGEDIT_ACTION action, WCHAR **argv, int *i)
WCHAR regedit[] = {'r','e','g','e','d','i','t',0};
_wperror(regedit);
output_message(STRING_CANNOT_OPEN_FILE, filename);
- exit(1);
+ return;
}
import_registry_file(reg_file);
if (realname)
@@ -150,7 +150,6 @@ static BOOL PerformRegAction(REGEDIT_ACTION action, WCHAR **argv, int *i)
exit(1);
break;
}
- return TRUE;
}
BOOL ProcessCmdLine(WCHAR *cmdline)
--
2.7.4
More information about the wine-patches
mailing list