[CP-stable]Add a check for the surface if it is valid #56301
+39
−0
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request is created by automatic cherry pick workflow
Issue Link:
flutter/flutter#155018
Changelog Description:
Summary:
A crash in Flutter SDK 3.24.1 affects Android apps using PlatformView, not limited to Google Maps. The crash occurs when the surface is released unexpectedly, causing subsequent draw calls to fail.
Impact Description:
Summary:
A crash in Flutter SDK 3.24.3 affects Android apps using
PlatformView
, not limited to Google Maps. The crash occurs when the surface is released unexpectedly, causing subsequent draw calls to fail.Impact:
This issue can lead to app crashes on Android for any
PlatformView
usage, affecting stability across a range of widgets and plugins that rely on native views.Workaround:
Is there a workaround for this issue?
Release the
Surface
in a regular way might avoid the issue, per flutter/flutter#155018 (comment)Risk:
What is the risk level of this cherry-pick?
Test Coverage:
Are you confident that your fix is well-tested by automated tests?
Validation Steps:
What are the steps to validate that this fix works?