diff options
author | kavsrf <kavsrf@gmail.com> | 2017-01-04 01:19:02 +0300 |
---|---|---|
committer | Mounir IDRASSI <mounir.idrassi@idrix.fr> | 2017-06-05 17:36:52 +0200 |
commit | d37d6d681061fdefc2a909b5975b40b604a27c62 (patch) | |
tree | 7d6f54a21d7aa32be5db1ba5be10ca87dc62cf7c /DcsRe | |
parent | f2e878683655b885f8ab2d365a40993ef942dea7 (diff) | |
download | VeraCrypt-DCS-d37d6d681061fdefc2a909b5975b40b604a27c62.tar.gz VeraCrypt-DCS-d37d6d681061fdefc2a909b5975b40b604a27c62.zip |
debug code cleanup
Diffstat (limited to 'DcsRe')
-rw-r--r-- | DcsRe/DcsRe.c | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/DcsRe/DcsRe.c b/DcsRe/DcsRe.c index 1d86e50..1f71f11 100644 --- a/DcsRe/DcsRe.c +++ b/DcsRe/DcsRe.c @@ -20,6 +20,13 @@ https://opensource.org/licenses/LGPL-3.0 #include <Guid/GlobalVariable.h>
#include "common/Tcdefs.h"
+#ifdef _M_X64
+#define ARCHdotEFI L"x64.efi"
+#else
+#define ARCHdotEFI L"IA32.efi"
+#endif
+
+
//////////////////////////////////////////////////////////////////////////
// Menu
//////////////////////////////////////////////////////////////////////////
@@ -52,11 +59,7 @@ SelectEfiVolume() for (i = 0; i < gFSCount; ++i) {
res = FileOpenRoot(gFSHandles[i], &file);
if(EFI_ERROR(res)) continue;
-#ifdef _M_X64
- if (!EFI_ERROR(FileExist(file, L"EFI\\Boot\\bootx64.efi"))) {
-#else
- if (!EFI_ERROR(FileExist(file, L"EFI\\Boot\\bootia32.efi"))) {
-#endif
+ if (!EFI_ERROR(FileExist(file, L"EFI\\Boot\\boot" ARCHdotEFI))) {
efiVolumesCount++;
efiVolumes[i] = file;
if (gFSHandles[i] != startHandle) {
@@ -95,11 +98,7 @@ SelectEfiVolume() //////////////////////////////////////////////////////////////////////////
EFI_STATUS
ActionBootWinPE(IN VOID* ctx) {
-#ifdef _M_X64
- return EfiExec(NULL, L"EFI\\Boot\\WinPE_bootx64.efi");
-#else
- return EfiExec(NULL, L"EFI\\Boot\\WinPE_bootia32.efi");
-#endif
+ return EfiExec(NULL, L"EFI\\Boot\\WinPE_boot" ARCHdotEFI);
}
EFI_STATUS
@@ -256,7 +255,7 @@ DcsReMain( item = DcsMenuAppend(item, L"Boot VeraCrypt loader from rescue disk", 'v', ActionDcsBoot, NULL);
}
- if (!EFI_ERROR(FileExist(NULL, L"EFI\\Boot\\WinPE_bootx64.efi"))) {
+ if (!EFI_ERROR(FileExist(NULL, L"EFI\\Boot\\WinPE_boot" ARCHdotEFI))) {
item = DcsMenuAppend(item, L"Boot Windows PE from rescue disk", 'w', ActionBootWinPE, NULL);
}
|