Commit b8fa1ab3 authored by Shakti Sahu's avatar Shakti Sahu Committed by Commit Bot

Fixed a crash in Background Fetch

Background fetch wasn't unregistering the provider on destruction which
is why there was a crash when trying to open download home.

Bug: 877670
Change-Id: I955a65694fb67aa8d4285a8e18ff2a37f2b220cc
Reviewed-on: https://chromium-review.googlesource.com/1211623Reviewed-by: default avatarRayan Kanso <rayankans@chromium.org>
Reviewed-by: default avatarDavid Trainor <dtrainor@chromium.org>
Commit-Queue: Shakti Sahu <shaktisahu@chromium.org>
Cr-Commit-Position: refs/heads/master@{#589370}
parent 78525669
......@@ -46,7 +46,9 @@ BackgroundFetchDelegateImpl::BackgroundFetchDelegateImpl(
offline_content_aggregator_->RegisterProvider(provider_namespace_, this);
}
BackgroundFetchDelegateImpl::~BackgroundFetchDelegateImpl() = default;
BackgroundFetchDelegateImpl::~BackgroundFetchDelegateImpl() {
offline_content_aggregator_->UnregisterProvider(provider_namespace_);
}
download::DownloadService* BackgroundFetchDelegateImpl::GetDownloadService() {
if (download_service_)
......
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