Module: wine Branch: master Commit: 4a4baf2566c595c0a79ef4cb4b6a0a4dbe1cc483 URL: http://source.winehq.org/git/wine.git/?a=commit;h=4a4baf2566c595c0a79ef4cb4b...
Author: Hugh McMaster hugh.mcmaster@outlook.com Date: Wed Sep 2 21:12:27 2015 +1000
regsvr32: Use correct exit code when LoadLibraryEx fails.
---
programs/regsvr32/regsvr32.c | 2 +- programs/regsvr32/regsvr32.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/programs/regsvr32/regsvr32.c b/programs/regsvr32/regsvr32.c index 68cb949..c0a9e13 100644 --- a/programs/regsvr32/regsvr32.c +++ b/programs/regsvr32/regsvr32.c @@ -107,7 +107,7 @@ static VOID *LoadProc(const WCHAR* strDll, const char* procName, HMODULE* DllHan if(!*DllHandle) { output_write(STRING_DLL_LOAD_FAILED, strDll); - ExitProcess(1); + ExitProcess(LOADLIBRARY_FAILED); } proc = (VOID *) GetProcAddress(*DllHandle, procName); if(!proc) diff --git a/programs/regsvr32/regsvr32.h b/programs/regsvr32/regsvr32.h index c021c55..85b4a72 100644 --- a/programs/regsvr32/regsvr32.h +++ b/programs/regsvr32/regsvr32.h @@ -19,6 +19,7 @@ */
/* Exit codes */ +#define LOADLIBRARY_FAILED 3 #define GETPROCADDRESS_FAILED 4
/* Resource strings */