-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
NullReferenceException in ShellToolbarAppearanceTracker.SetColors
on Android
#12460
Comments
We've moved this issue to the Backlog milestone. This means that it is not going to be worked on for the coming release. We will reassess the backlog following the current release and consider this item at that time. To learn more about our issue management process and to have better expectation regarding different types of issues you can read our Triage Process. |
@BioTurboNick those should never be
|
This line is present in the
|
Some other crashes recorded by AppCenter definitely point to something wrong with disposal:
|
Found a workaround that works for me. |
Description
Had 3 reports of crashes in this method from two devices, on Android 9 and 10, via AppCenter
Here's the code in question:
maui/src/Controls/src/Core/Compatibility/Handlers/Shell/Android/ShellToolbarAppearanceTracker.cs
Lines 34 to 39 in a3b135f
Is the MAUI library using nullable types? If not, there's no verification that
_shellContext
is not null when the object is constructed. And if it's at all possible to be accessed after being disposed, that would also produce this exception.Even if
_shellContext
is not null, is.Shell
, or.Shell.Toolbar
guaranteed to not be null?Steps to Reproduce
Unknown
Link to public reproduction project repository
n/a
Version with bug
7.0 (current)
Last version that worked well
Unknown/Other
Affected platforms
Android
Affected platform versions
Android 9-10
Did you find any workaround?
No response
Relevant log output
The text was updated successfully, but these errors were encountered: