Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix crash on startup for older Android devices #12139

Merged

Conversation

rubenp02
Copy link
Contributor

Fix crash on startup for older Android devices

Description

The overload to the registerReceiver method with a flags parameter was introduced in API level 26 (Android 8.0), which leads to an instant crash on startup on devices running older versions of Android. Adjusted the implementation to use the previous signature of registerReceiver on devices with API levels below 26.

Checklist:

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

The overload to the registerReceiver method with a flags parameter was
introduced in API level 26 (Android 8.0), which leads to an instant
crash on startup on devices running older versions of Android. Adjusted
the implementation to use the previous signature of registerReceiver on
devices with API levels below 26.
@rubenp02 rubenp02 force-pushed the hotfix/fix-android-7-startup-crash branch from 0490ccf to 2ed2acd Compare November 26, 2024 15:21
@HTRamsey HTRamsey merged commit d23d606 into mavlink:master Nov 26, 2024
2 checks passed
@HTRamsey
Copy link
Collaborator

@rubenp02 just so you know, when we switch to Qt6.8, the minimum supported android will be 9.0. https://doc.qt.io/qt-6.8/whatsnew68.html

@rubenp02 rubenp02 deleted the hotfix/fix-android-7-startup-crash branch November 27, 2024 08:40
@rubenp02
Copy link
Contributor Author

I wasn't aware, thank you! That's too bad, many Android-based GCS are on Android 7 (like the SkyDroid H16, which is very widely used in China).

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