mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-05 18:57:19 +02:00
[Analyzers][CPP]Changes to fix warning 26493 on src/modules/ (A to F) (#23482)
starting with letter A to Letter F
This commit is contained in:
@@ -212,7 +212,7 @@ void FancyZonesSettings::LoadSettings()
|
||||
std::wstring apps = std::move(*val);
|
||||
std::vector<std::wstring> excludedApps;
|
||||
auto excludedUppercase = apps;
|
||||
CharUpperBuffW(excludedUppercase.data(), (DWORD)excludedUppercase.length());
|
||||
CharUpperBuffW(excludedUppercase.data(), static_cast<DWORD>(excludedUppercase.length()));
|
||||
std::wstring_view view(excludedUppercase);
|
||||
view = left_trim<wchar_t>(trim<wchar_t>(view));
|
||||
|
||||
@@ -236,7 +236,7 @@ void FancyZonesSettings::LoadSettings()
|
||||
if (auto val = values.get_int_value(NonLocalizable::OverlappingZonesAlgorithmID))
|
||||
{
|
||||
// Avoid undefined behavior
|
||||
if (*val >= 0 || *val < (int)OverlappingZonesAlgorithm::EnumElements)
|
||||
if (*val >= 0 || *val < static_cast<int>(OverlappingZonesAlgorithm::EnumElements))
|
||||
{
|
||||
auto algorithm = (OverlappingZonesAlgorithm)*val;
|
||||
if (m_settings.overlappingZonesAlgorithm != algorithm)
|
||||
|
||||
Reference in New Issue
Block a user