Fix the IconLoadingPipeline::OnReadWebAppIcon crash issue.
CL:2454920 could fix the issue. This CL is used to make it better, because SkBitmap could be empty: https://source.chromium.org/chromium/chromium/src/+/master:chrome/browser/web_applications/web_app_icon_manager.cc;drc=a450ab794839b63f9c2ba982f738945f90e9fee2;l=422 So for the empty SkBitmap, we can return an empty imageskia, and don't need to resize or add the ImageSkiaRep. BUG=1137484 Change-Id: I0f27c75885a9ced8fbc2f086729b0d58b42be725 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2470821 Commit-Queue: Nancy Wang <nancylingwang@chromium.org> Reviewed-by: Dominick Ng <dominickn@chromium.org> Cr-Commit-Position: refs/heads/master@{#817245}
This commit is contained in:
@ -953,7 +953,7 @@ void IconLoadingPipeline::OnReadWebAppIcon(
|
||||
++it;
|
||||
}
|
||||
|
||||
if (it == icon_bitmaps.end()) {
|
||||
if (it == icon_bitmaps.end() || it->second.empty()) {
|
||||
MaybeApplyEffectsAndComplete(gfx::ImageSkia());
|
||||
return;
|
||||
}
|
||||
|
Reference in New Issue
Block a user