alloy: win: Fix range check for system cursors (fixes issue #3270)

This commit is contained in:
Marshall Greenblatt 2022-04-14 14:06:58 -04:00
parent cd1e7883ce
commit d51f2327f7
1 changed files with 2 additions and 1 deletions

View File

@ -131,7 +131,8 @@ LPCWSTR ToCursorID(ui::mojom::CursorType type) {
}
bool IsSystemCursorID(LPCWSTR cursor_id) {
return cursor_id >= IDC_ARROW; // See WinUser.h
// Check the range of values from WinUser.h.
return cursor_id >= IDC_ARROW && cursor_id <= IDC_HELP;
}
} // namespace