Skip to content

Fix Opencv Crash Region out of bounds#1958

Merged
reconman merged 1 commit intomasterfrom
prevent-checking-of-invalid-size-in-opencv
May 13, 2025
Merged

Fix Opencv Crash Region out of bounds#1958
reconman merged 1 commit intomasterfrom
prevent-checking-of-invalid-size-in-opencv

Conversation

@ArthurKun21
Copy link
Copy Markdown
Collaborator

@ArthurKun21 ArthurKun21 commented Jan 31, 2025

Opencv Crash Region out of bounds

Pull Request Type

  • Bugfix
  • Feature Implementation
  • Documentation
  • Other

Related issue

Description

For some odd reason, I encountered a problem wherein when checking support's skills and it was out of frame(only the servant image was visible and it matched with the template) it would led to crash. Changing the mat to null-able resolves this issue.

Screenshots

Testing

  1. Ensure the battle config has a servant selected and skills enabled.
  2. Go to the support screen.
  3. Find the servant and when found, scroll the screen and ensure that the servant is visible but not the skills.
  4. Run the script
  5. ....
  6. Crash!

Additional context

This is edge case but damn

@ArthurKun21 ArthurKun21 changed the title Opencv Crash Region out of bounds Fix Opencv Crash Region out of bounds Jan 31, 2025
@github-actions
Copy link
Copy Markdown

github-actions bot commented Jan 31, 2025

Build 237

Download the latest APK for testing here

Note

You need a GitHub account to download the APK.

This URL is valid as long as the artifact has not expired yet.

@ArthurKun21 ArthurKun21 requested a review from reconman January 31, 2025 11:03
@ArthurKun21 ArthurKun21 closed this Mar 9, 2025
@ArthurKun21 ArthurKun21 deleted the prevent-checking-of-invalid-size-in-opencv branch March 9, 2025 10:08
@ArthurKun21 ArthurKun21 restored the prevent-checking-of-invalid-size-in-opencv branch May 13, 2025 03:46
@ArthurKun21 ArthurKun21 reopened this May 13, 2025
@ArthurKun21 ArthurKun21 force-pushed the prevent-checking-of-invalid-size-in-opencv branch from 17587ad to cf00f76 Compare May 13, 2025 03:47
@ArthurKun21 ArthurKun21 requested review from reconman and removed request for reconman May 13, 2025 20:49
@reconman
Copy link
Copy Markdown
Collaborator

Seems like this only happens with the last few app versions, so since I've updated to the newest OpenCV version.

Thanks for the fix, I had no idea why it was crashing.

@reconman reconman merged commit 4870850 into master May 13, 2025
1 check passed
@reconman reconman deleted the prevent-checking-of-invalid-size-in-opencv branch May 13, 2025 20:53
wowuz pushed a commit to wowuz/FGA that referenced this pull request May 19, 2025
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.

app crash due to opencv out of bounds

2 participants