mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 812867 - Discard invalid favicon images (r=mfinkle)
This commit is contained in:
parent
2a8196727f
commit
9673229f77
@ -705,7 +705,7 @@ public class BrowserToolbar implements ViewSwitcher.ViewFactory,
|
||||
if (Tabs.getInstance().getSelectedTab().getState() == Tab.STATE_LOADING)
|
||||
return;
|
||||
|
||||
if (image != null && image.getWidth() > 0 && image.getHeight() > 0) {
|
||||
if (image != null) {
|
||||
image = Bitmap.createScaledBitmap(image, mFaviconSize, mFaviconSize, false);
|
||||
mFavicon.setImageBitmap(image);
|
||||
} else {
|
||||
|
@ -296,8 +296,10 @@ public class Favicons {
|
||||
|
||||
image = downloadFavicon(faviconUrl);
|
||||
|
||||
if (image != null) {
|
||||
if (image != null && image.getWidth() > 0 && image.getHeight() > 0) {
|
||||
saveFaviconToDb(image);
|
||||
} else {
|
||||
image = null;
|
||||
}
|
||||
|
||||
return image;
|
||||
|
Loading…
Reference in New Issue
Block a user