mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-11-10 08:50:10 +01:00
Chore (Windows): use standard libc api
This commit is contained in:
1 parent
85a31c7c69
commit
866c7303e6
1 file changed
+1
-1
@@ -38,7 +38,7 @@ const char* ffDetectBootmgr(FFBootmgrResult* result)
|
||||
|
||||
uint8_t buffer[2048];
|
||||
wchar_t key[16];
|
||||
wsprintfW(key, L"Boot%04X", value);
|
||||
swprintf(key, sizeof(key) / sizeof(*key), L"Boot%04X", value);
|
||||
uint32_t size = GetFirmwareEnvironmentVariableW(key, L"{" FF_EFI_GLOBAL_GUID L"}", buffer, sizeof(buffer));
|
||||
if (size < sizeof(FFEfiLoadOption) || size == sizeof(buffer))
|
||||
return "GetFirmwareEnvironmentVariableW(Boot####) failed";
|
||||
|
||||
Reference in new issue
Block a user