Skip to content

Conversation

@tspiller
Copy link
Collaborator

Description

The ShouldBindingBeVisible() function was not checking that deviceIndex passed in was a valid index in the current Control Scheme's deviceRequirements array. This could lead to ArgumentOutOfRangeException error when accessing the element, particularly in the case of an empty array.

Testing status & QA

Local testing / automated tests

Overall Product Risks

Simple additional check for valid index

Complexity: 0
Halo Effect: 0

Comments to reviewers

Checklist

Before review:

  • Changelog entry added.
    • Explains the change in Changed, Fixed, Added sections.
    • For API change contains an example snippet and/or migration example.
    • JIRA ticket linked, example (case %%). If it is a private issue, just add the case ID without a link.
    • Jira port for the next release set as "Resolved".
  • Tests added/changed, if applicable.
    • Functional tests Area_CanDoX, Area_CanDoX_EvenIfYIsTheCase, Area_WhenIDoX_AndYHappens_ThisIsTheResult.
    • Performance tests.
    • Integration tests.
  • Docs for new/changed API's.
    • Xmldoc cross references are set correctly.
    • Added explanation how the API works.
    • Usage code examples added.
    • The manual is updated, if needed.

During merge:

  • Commit message for squash-merge is prefixed with one of the list:
    • NEW: ___.
    • FIX: ___.
    • DOCS: ___.
    • CHANGE: ___.
    • RELEASE: 1.1.0-preview.3.

After merge:

  • Create forward/backward port if needed. If you are blocked from creating a forward port now please add a task to ISX-1444.

@tspiller tspiller requested a review from ekcoh November 14, 2024 11:16
@tspiller tspiller marked this pull request as ready for review November 14, 2024 11:16
@tspiller tspiller force-pushed the isxb-1129-current-control-scheme-visibility branch from 1ab802b to 4dccfbf Compare November 19, 2024 10:00
Copy link
Collaborator

@ekcoh ekcoh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix looks legit to circumvent the problem, but why would the function the called with an invalid deviceIndex in the first place? What I am after is that there must be an earlier point where we should have detected that the index is invalid?

@tspiller tspiller merged commit d40a2ea into develop Nov 25, 2024
77 checks passed
@tspiller tspiller deleted the isxb-1129-current-control-scheme-visibility branch November 25, 2024 13:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants