commit | 58d0dac03ef2c5361f522ae29b7f65d9a92e7de4 | [log] [tgz] |
---|---|---|
author | Lukasz Anforowicz <[email protected]> | Fri Mar 23 15:48:10 2018 |
committer | Commit Bot <[email protected]> | Fri Mar 23 15:48:10 2018 |
tree | 86f880d97d9714cba3787365c08a3746c8e1ca8d | |
parent | 4f44caa1b4678e6a149953c156b004f1becc4a20 [diff] |
Call NotifyWillBeDestroyed before destroying TestBrowserContext. Planned modifications to SpareRenderProcessHostManager (see https://crrev.com/c/963405) require making sure that BrowserContext::NotifyWillBeDestroyed is called before destroying the context - otherwise some RenderProcessHost(s) (e.g. the spare one) can survive longer than a BrowserContext leading to UaF when the RenderProcessHost(s) are eventually destroyed later (potentially in a different unit test :-). This CL makes sure that NotifyWillBeDestroyed will be called from the destructor of TestBrowserContext (and from a few other subclasses of BrowserContext as appropriate). Destroying the BrowserContext expands the scope of the requirement to properly emulate browser threads in the tests by using TestBrowserThreadBundle in a few more places. Bug: 808114 Change-Id: I60b959e4969c39bededd6de7a3a51a8fdf12e387 Tbr: [email protected] Tbr: [email protected] Tbr: [email protected] Reviewed-on: https://chromium-review.googlesource.com/964804 Commit-Queue: Łukasz Anforowicz <[email protected]> Reviewed-by: Sami Kyöstilä <[email protected]> Reviewed-by: Sergey Volk <[email protected]> Reviewed-by: Istiaque Ahmed <[email protected]> Reviewed-by: Alex Moshchuk <[email protected]> Cr-Commit-Position: refs/heads/master@{#545463}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .