Module: wine Branch: master Commit: 3bdb64149b9d89449a43757f298f33f53f636af9 URL: http://source.winehq.org/git/wine.git/?a=commit;h=3bdb64149b9d89449a43757f29...
Author: Jason Edmeades us@edmeades.me.uk Date: Tue Feb 20 18:03:32 2007 +0000
cmd.exe: Support return code if fail to launch program.
---
programs/cmd/wcmdmain.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/programs/cmd/wcmdmain.c b/programs/cmd/wcmdmain.c index 8077fb8..fa17d93 100755 --- a/programs/cmd/wcmdmain.c +++ b/programs/cmd/wcmdmain.c @@ -662,6 +662,9 @@ char filetorun[MAX_PATH]; } if (!status) { WCMD_print_error (); + /* If a command fails to launch, it sets errorlevel 9009 - which + does not seem to have any associated constant definition */ + errorlevel = 9009; return; } if (!console) errorlevel = 0;