Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(765)

Issue 2883323002: [ios] Fix clean shutdown of Chrome on iOS. (Closed)

Created:
3 years, 7 months ago by sdefresne
Modified:
3 years, 7 months ago
CC:
chromium-reviews, marq+watch_chromium.org, ios-reviews+chrome_chromium.org, noyau+watch_chromium.org, ios-reviews_chromium.org, pkl (ping after 24h if needed)
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

[ios] Fix clean shutdown of Chrome on iOS. Drop the references to SpotlightManager and BrowserViewWrangler in MainController -stopChromeMain before destroying IOSChromeMain as IOSChromeMain leads to the destruction of ChromeBrowserState and both SpotlightManager and BrowserViewWrangler must not outlive the ChromeBrowserState. Fix SpotlightTopSitesBridge destructor by keeping a reference to history::TopSites as __weak pointer are set to nil before the ivar are destroyed, thus owner_->topSites is null by that point. Fix ToolsMenuButtonObserverBridge to destroy the observer bridge when setting _model to null to avoid DCHECK. BUG=722879 Review-Url: https://codereview.chromium.org/2883323002 Cr-Commit-Position: refs/heads/master@{#472437} Committed: https://chromium.googlesource.com/chromium/src/+/8ac159105b78c8987a16faa4113d18b37682566b

Patch Set 1 #

Total comments: 2

Patch Set 2 : Rebase on origin/master. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+13 lines, -7 lines) Patch
M ios/chrome/app/main_controller.mm View 1 1 chunk +2 lines, -0 lines 0 comments Download
M ios/chrome/app/spotlight/topsites_spotlight_manager.mm View 5 chunks +10 lines, -7 lines 0 comments Download
M ios/chrome/browser/ui/toolbar/tools_menu_button_observer_bridge.mm View 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 21 (12 generated)
sdefresne
Please take a look.
3 years, 7 months ago (2017-05-16 16:16:02 UTC) #3
sdefresne
rohitrao: please take a look as this fix crashes / DCHECK failures during shutdown of ...
3 years, 7 months ago (2017-05-16 16:17:40 UTC) #7
rohitrao (ping after 24h)
https://codereview.chromium.org/2883323002/diff/1/ios/chrome/app/main_controller.mm File ios/chrome/app/main_controller.mm (right): https://codereview.chromium.org/2883323002/diff/1/ios/chrome/app/main_controller.mm#newcode956 ios/chrome/app/main_controller.mm:956: _spotlightManager.reset(); There's no guarantee that this call will destroy ...
3 years, 7 months ago (2017-05-16 16:41:02 UTC) #11
sdefresne
On 2017/05/16 16:41:02, rohitrao (ping after 24h) wrote: > https://codereview.chromium.org/2883323002/diff/1/ios/chrome/app/main_controller.mm > File ios/chrome/app/main_controller.mm (right): > ...
3 years, 7 months ago (2017-05-16 16:42:41 UTC) #12
sdefresne
https://codereview.chromium.org/2883323002/diff/1/ios/chrome/app/main_controller.mm File ios/chrome/app/main_controller.mm (right): https://codereview.chromium.org/2883323002/diff/1/ios/chrome/app/main_controller.mm#newcode957 ios/chrome/app/main_controller.mm:957: _browserViewWrangler.reset(); There is no guarantee that this will destroy ...
3 years, 7 months ago (2017-05-16 16:44:40 UTC) #13
rohitrao (ping after 24h)
lgtm
3 years, 7 months ago (2017-05-16 16:58:44 UTC) #14
stkhapugin
lgtm, thanks for looking into this
3 years, 7 months ago (2017-05-17 12:27:15 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2883323002/20001
3 years, 7 months ago (2017-05-17 13:10:04 UTC) #18
commit-bot: I haz the power
3 years, 7 months ago (2017-05-17 13:21:30 UTC) #21
Message was sent while issue was closed.
Committed patchset #2 (id:20001) as
https://chromium.googlesource.com/chromium/src/+/8ac159105b78c8987a16faa4113d...

Powered by Google App Engine
This is Rietveld 408576698