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

[Impeller] fix NPE caused by implicit sk_sp to fml::Status conversion. #53177

Merged
merged 3 commits into from
Jun 3, 2024

Conversation

jonahwilliams
Copy link
Member

nullptr is converted to fml::Status::OK(nullptr), which we don't null check. Change this to consistently use fml::Status

Discovered in flutter/flutter#148851

@jonahwilliams jonahwilliams requested a review from gaaclarke June 3, 2024 19:43
Copy link
Member

@gaaclarke gaaclarke left a comment

Choose a reason for hiding this comment

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

lgtm!

@jonahwilliams jonahwilliams added the autosubmit Merge PR when tree becomes green via auto submit App label Jun 3, 2024
}

switch (format) {
case kPNG: {
auto png_image = SkPngEncoder::Encode(nullptr, raster_image.get(), {});

if (png_image == nullptr) {
FML_LOG(ERROR) << "Could not convert raster image to PNG.";
Copy link
Member

Choose a reason for hiding this comment

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

Wait, do we want to maintain these logs somewhere?

Copy link
Member Author

Choose a reason for hiding this comment

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

These strings get returned to the dart:ui layer and printed there as an error.

@auto-submit auto-submit bot merged commit 60a7bb2 into flutter:main Jun 3, 2024
31 checks passed
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jun 3, 2024
auto-submit bot pushed a commit to flutter/flutter that referenced this pull request Jun 3, 2024
…149623)

flutter/engine@ea72558...60a7bb2

2024-06-03 [email protected] [Impeller] fix NPE caused by implicit sk_sp to fml::Status conversion. (flutter/engine#53177)
2024-06-03 [email protected] Migrate off deprecated GrVkBackendContext fields (flutter/engine#53122)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-engine-flutter-autoroll
Please CC [email protected],[email protected],[email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
autosubmit Merge PR when tree becomes green via auto submit App
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants