Commit fe5ab212 authored by Mikel Astiz's avatar Mikel Astiz Committed by Commit Bot

Avoid crashes if all favicons already processed

We have evidence of DownloadCurrentCandidateOrAskFaviconService()
crashing due to current_candidate() being null, at least until recent
fixes.

Temporarily and as a precaution, we return early in case the problematic
scenario is reproduced. We suspect this condition is not reached in
trunk, but it's a simple workaround to cherry-pick.

Bug: 828196
Change-Id: I41e2236f341a9ed9e18a950540f096e9de42df0b
Reviewed-on: https://chromium-review.googlesource.com/1002093Reviewed-by: default avatarPeter Kotwicz <pkotwicz@chromium.org>
Commit-Queue: Mikel Astiz <mastiz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#549264}
parent cfbaa984
......@@ -458,6 +458,10 @@ void FaviconHandler::OnGotInitialHistoryDataAndIconURLCandidates() {
return;
}
if (!current_candidate()) {
return;
}
if (!initial_history_result_expired_or_incomplete_ &&
current_candidate()->icon_url == notification_icon_url_ &&
current_candidate()->icon_type == notification_icon_type_) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment