fixes BZ #42030
Signed-off-by: Eric Pouech eric.pouech@gmail.com
--- programs/winedbg/winedbg.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/programs/winedbg/winedbg.c b/programs/winedbg/winedbg.c index 4cd2979dce3..45a7edfb309 100644 --- a/programs/winedbg/winedbg.c +++ b/programs/winedbg/winedbg.c @@ -675,7 +675,7 @@ int main(int argc, char** argv) /* parse options */ while (argc > 0 && argv[0][0] == '-') { - if (!strcmp(argv[0], "--command")) + if (!strcmp(argv[0], "--command") && argc > 1) { argc--; argv++; hFile = parser_generate_command_file(argv[0], NULL); @@ -687,7 +687,7 @@ int main(int argc, char** argv) argc--; argv++; continue; } - if (!strcmp(argv[0], "--file")) + if (!strcmp(argv[0], "--file") && argc > 1) { argc--; argv++; hFile = CreateFileA(argv[0], GENERIC_READ|DELETE, 0,