mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-09-13 02:42:09 +02:00
Windows: silense compiler warnings
This commit is contained in:
@@ -31,8 +31,7 @@ static const char* getOsNameByWinbrand(FFstrbuf* osName)
|
||||
//https://dennisbabkin.com/blog/?t=how-to-tell-the-real-version-of-windows-your-app-is-running-on#ver_string
|
||||
if(HMODULE __attribute__((__cleanup__(wrapFreeLibrary))) hWinbrand = LoadLibraryW(L"winbrand.dll"))
|
||||
{
|
||||
PWSTR(WINAPI* BrandingFormatString)(PCWSTR);
|
||||
(FARPROC&)BrandingFormatString = GetProcAddress(hWinbrand, "BrandingFormatString");
|
||||
auto BrandingFormatString = (PWSTR(WINAPI*)(PCWSTR))GetProcAddress(hWinbrand, "BrandingFormatString");
|
||||
if(!BrandingFormatString)
|
||||
return "GetProcAddress(BrandingFormatString) failed";
|
||||
|
||||
|
||||
@@ -147,7 +147,8 @@ static uint32_t getShellInfo(FFTerminalShellResult* result, uint32_t pid)
|
||||
|
||||
if(snapshot)
|
||||
{
|
||||
MODULEENTRY32W module = { .dwSize = sizeof(module) };
|
||||
MODULEENTRY32W module;
|
||||
module.dwSize = sizeof(module);
|
||||
for(BOOL success = Module32FirstW(snapshot, &module); success; success = Module32NextW(snapshot, &module))
|
||||
{
|
||||
if(wcsncmp(module.szModule, L"clink_dll_", wcslen(L"clink_dll_")) == 0)
|
||||
|
||||
Reference in New Issue
Block a user