mirror of
https://github.com/veracrypt/VeraCrypt.git
synced 2025-12-29 10:09:43 -06:00
Windows: Installer and Traveler Disk Setup both always copy 32-bit and 64-bit executable binaries.
This commit is contained in:
@@ -641,6 +641,18 @@ BOOL DoFilesInstall (HWND hwndDlg, char *szDestDir)
|
||||
continue; // Destination = target
|
||||
}
|
||||
|
||||
// skip files that don't apply to the current architecture
|
||||
if ( (Is64BitOs () && (strcmp (szFiles[i], "AVeraCrypt-x64.exe") == 0))
|
||||
|| (Is64BitOs () && (strcmp (szFiles[i], "AVeraCryptExpander-x64.exe") == 0))
|
||||
|| (Is64BitOs () && (strcmp (szFiles[i], "AVeraCrypt Format-x64.exe") == 0))
|
||||
|| (!Is64BitOs () && (strcmp (szFiles[i], "AVeraCrypt-x86.exe") == 0))
|
||||
|| (!Is64BitOs () && (strcmp (szFiles[i], "AVeraCryptExpander-x86.exe") == 0))
|
||||
|| (!Is64BitOs () && (strcmp (szFiles[i], "AVeraCrypt Format-x86.exe") == 0))
|
||||
)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
if (*szFiles[i] == 'A')
|
||||
StringCbCopyA (szDir, sizeof(szDir), szDestDir);
|
||||
else if (*szFiles[i] == 'D')
|
||||
@@ -699,18 +711,36 @@ BOOL DoFilesInstall (HWND hwndDlg, char *szDestDir)
|
||||
StringCbCopyNA (curFileName, sizeof(curFileName), "VeraCrypt-x64.exe", sizeof ("VeraCrypt-x64.exe"));
|
||||
}
|
||||
|
||||
if (Is64BitOs ()
|
||||
&& strcmp (szFiles[i], "AVeraCrypt-x86.exe") == 0)
|
||||
{
|
||||
StringCbCopyNA (curFileName, sizeof(curFileName), "VeraCrypt.exe", sizeof ("VeraCrypt.exe"));
|
||||
}
|
||||
|
||||
if (Is64BitOs ()
|
||||
&& strcmp (szFiles[i], "AVeraCryptExpander.exe") == 0)
|
||||
{
|
||||
StringCbCopyNA (curFileName, sizeof(curFileName), "VeraCryptExpander-x64.exe", sizeof ("VeraCryptExpander-x64.exe"));
|
||||
}
|
||||
|
||||
if (Is64BitOs ()
|
||||
&& strcmp (szFiles[i], "AVeraCryptExpander-x86.exe") == 0)
|
||||
{
|
||||
StringCbCopyNA (curFileName, sizeof(curFileName), "VeraCryptExpander.exe", sizeof ("VeraCryptExpander.exe"));
|
||||
}
|
||||
|
||||
if (Is64BitOs ()
|
||||
&& strcmp (szFiles[i], "AVeraCrypt Format.exe") == 0)
|
||||
{
|
||||
StringCbCopyNA (curFileName, sizeof(curFileName), "VeraCrypt Format-x64.exe", sizeof ("VeraCrypt Format-x64.exe"));
|
||||
}
|
||||
|
||||
if (Is64BitOs ()
|
||||
&& strcmp (szFiles[i], "AVeraCrypt Format-x86.exe") == 0)
|
||||
{
|
||||
StringCbCopyNA (curFileName, sizeof(curFileName), "VeraCrypt Format.exe", sizeof ("VeraCrypt Format.exe"));
|
||||
}
|
||||
|
||||
if (!bDevm)
|
||||
{
|
||||
bResult = FALSE;
|
||||
|
||||
@@ -28,6 +28,12 @@ static char *szFiles[]=
|
||||
"AVeraCrypt.exe",
|
||||
"AVeraCryptExpander.exe",
|
||||
"AVeraCrypt Format.exe",
|
||||
"AVeraCrypt-x86.exe",
|
||||
"AVeraCryptExpander-x86.exe",
|
||||
"AVeraCrypt Format-x86.exe",
|
||||
"AVeraCrypt-x64.exe",
|
||||
"AVeraCryptExpander-x64.exe",
|
||||
"AVeraCrypt Format-x64.exe",
|
||||
"Averacrypt.sys",
|
||||
"Averacrypt-x64.sys",
|
||||
"Dveracrypt.sys",
|
||||
|
||||
Reference in New Issue
Block a user