mirror of
https://github.com/pbatard/rufus.git
synced 2025-06-06 01:21:24 -04:00
[net] fix incorrect architectures when querying for updates
This commit is contained in:
parent
f27dda1164
commit
6280e8020a
5 changed files with 33 additions and 39 deletions
28
src/stdfn.c
28
src/stdfn.c
|
@ -223,22 +223,18 @@ BOOL is_x64(void)
|
|||
return ret;
|
||||
}
|
||||
|
||||
int GetCpuArch(void)
|
||||
{
|
||||
SYSTEM_INFO info = { 0 };
|
||||
GetNativeSystemInfo(&info);
|
||||
switch (info.wProcessorArchitecture) {
|
||||
case PROCESSOR_ARCHITECTURE_AMD64:
|
||||
return ARCH_X86_64;
|
||||
case PROCESSOR_ARCHITECTURE_INTEL:
|
||||
return ARCH_X86_64;
|
||||
case PROCESSOR_ARCHITECTURE_ARM64:
|
||||
return ARCH_ARM_64;
|
||||
case PROCESSOR_ARCHITECTURE_ARM:
|
||||
return ARCH_ARM_32;
|
||||
default:
|
||||
return ARCH_UNKNOWN;
|
||||
}
|
||||
const char* GetAppArchName(void) {
|
||||
#if defined(_M_AMD64)
|
||||
return "x64";
|
||||
#elif defined(_M_IX86)
|
||||
return "x86";
|
||||
#elif defined(_M_ARM64)
|
||||
return "arm64";
|
||||
#elif defined(_M_ARM)
|
||||
return "arm";
|
||||
#else
|
||||
return "unknown";
|
||||
#endif
|
||||
}
|
||||
|
||||
static const char* GetEdition(DWORD ProductType)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue