Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[M119] [HFM] Don't bind WebContents pointer in HSTS query callback
Because the call to NetworkContext::IsHSTSActiveForHost() is async, it is possible for the WebContents to be destroyed before the callback to MaybeCreateLoaderOnHstsQueryCompleted() is run. This changes the callback to get the WebContents using `frame_tree_node_id_` again and verify that it is still valid when the callback is run, and similarly reconstruct the Profile and TabHelper rather than needing to bind them into the callback. (cherry picked from commit 4208e44) Fixed: 1499515 Change-Id: I52ffefc5586771d21f4860eefca09b933b87ec6d Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5014874 Reviewed-by: Mustafa Emre Acer <meacer@chromium.org> Commit-Queue: Chris Thompson <cthomp@chromium.org> Cr-Original-Commit-Position: refs/heads/main@{#1221998} Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5021108 Auto-Submit: Chris Thompson <cthomp@chromium.org> Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com> Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com> Cr-Commit-Position: refs/branch-heads/6045@{#1291} Cr-Branched-From: 905e8bd-refs/heads/main@{#1204232}
- Loading branch information