From a21b2270e8db93d231fa0a3d60776043c9a0f9bc Mon Sep 17 00:00:00 2001 From: Mounir IDRASSI Date: Sat, 4 Dec 2021 23:55:41 +0100 Subject: Windows: Implement TESTSIGNING build configuration that allows running under Windows Vista,7, 8 and 8.1. --- src/Setup/Setup.c | 50 +++++++++++++++++++++++++------------------------- 1 file changed, 25 insertions(+), 25 deletions(-) (limited to 'src/Setup/Setup.c') diff --git a/src/Setup/Setup.c b/src/Setup/Setup.c index 4b850999..6423b6b0 100644 --- a/src/Setup/Setup.c +++ b/src/Setup/Setup.c @@ -2944,31 +2944,6 @@ int WINAPI wWinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance, wchar_t *lpsz SelfExtractStartupInit(); -#ifdef PORTABLE - lpszTitle = L"VeraCrypt Portable"; -#else - lpszTitle = L"VeraCrypt Setup"; -#endif - /* Call InitApp to initialize the common code */ - InitApp (hInstance, NULL); - -#ifndef PORTABLE - if (IsAdmin () != TRUE) - if (MessageBoxW (NULL, GetString ("SETUP_ADMIN"), lpszTitle, MB_YESNO | MB_ICONQUESTION) != IDYES) - { - FinalizeApp (); - exit (1); - } -#endif - /* Setup directory */ - { - wchar_t *s; - GetModuleFileName (NULL, SetupFilesDir, ARRAYSIZE (SetupFilesDir)); - s = wcsrchr (SetupFilesDir, L'\\'); - if (s) - s[1] = 0; - } - /* Parse command line arguments */ if (lpszCommandLine[0] == L'/') @@ -3001,6 +2976,31 @@ int WINAPI wWinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance, wchar_t *lpsz } } +#ifdef PORTABLE + lpszTitle = L"VeraCrypt Portable"; +#else + lpszTitle = L"VeraCrypt Setup"; +#endif + /* Call InitApp to initialize the common code */ + InitApp (hInstance, NULL); + +#ifndef PORTABLE + if (IsAdmin () != TRUE) + if (MessageBoxW (NULL, GetString ("SETUP_ADMIN"), lpszTitle, MB_YESNO | MB_ICONQUESTION) != IDYES) + { + FinalizeApp (); + exit (1); + } +#endif + /* Setup directory */ + { + wchar_t *s; + GetModuleFileName (NULL, SetupFilesDir, ARRAYSIZE (SetupFilesDir)); + s = wcsrchr (SetupFilesDir, L'\\'); + if (s) + s[1] = 0; + } + if (bMakePackage) { /* Create self-extracting package */ -- cgit v1.2.3