mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-05 02:36:19 +02:00
[Analyzers][CPP]Changes to fix warning 26493 on PowerToys/tools (#23674)
This commit is contained in:
@@ -15,7 +15,7 @@ namespace
|
||||
};
|
||||
|
||||
auto callback = [](HMONITOR monitor, HDC, RECT*, LPARAM prm) -> BOOL {
|
||||
std::wostream& os = *((capture*)prm)->os;
|
||||
std::wostream& os = *(reinterpret_cast<capture*>(prm))->os;
|
||||
MONITORINFOEX mi;
|
||||
mi.cbSize = sizeof(mi);
|
||||
|
||||
@@ -48,7 +48,7 @@ namespace
|
||||
|
||||
capture c;
|
||||
c.os = &os;
|
||||
if (EnumDisplayMonitors(nullptr, nullptr, callback, (LPARAM)&c))
|
||||
if (EnumDisplayMonitors(nullptr, nullptr, callback, reinterpret_cast<LPARAM>(& c)))
|
||||
{
|
||||
os << "EnumDisplayMonitors OK\n";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user