Pseudo-USS: Fix BridgeBuilder destruction for non-UI-thread types
BridgeBuilder is constructed on the UI thread, but then basically lives on a background thread - in particular hands out WeakPtrs to itself, for use on the background thread. However, before this CL, its destruction used to happen on the UI thread again. This introduces a race between invalidating the WeakPtrs (on the UI thread) and using them (on the background thread). The fix is to destroy the BridgeBuilder on the background thread, via base::OnTaskRunnerDeleter. Bug: 970354, 971881, 906995 Change-Id: I2acbdb63de7d291f2703242691c30f48acda5907 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1649503 Commit-Queue: Marc Treib <treib@chromium.org> Reviewed-by:Mikel Astiz <mastiz@chromium.org> Cr-Commit-Position: refs/heads/master@{#667098}
Showing
Please register or sign in to comment