DescriptionMake ScriptLoader into a ResourceOwner
This change turns ScriptLoader a ResourceOwner, that ensures that
it subscribes Resource if the owner has a reference to it, and that
it unsubscribes the Resource otherwise. Before this change,
There are some situation where ScriptLoader has a reference to Resource
but doesn't subscribe it, that is error prone and left deleted instance
being subscribed. ResourceOwner guarantees reference and subscription
consistency.
This is the second attempt to land this change. The original one was
reverted at r173996 because it caused a lot of crashes. These crahses
shouldn't happen with this revised version.
TEST=script-cancel-crash.html
BUG=368551, 372242
TBR=eseidel@chromium.org, japhet@chromium.org, dglazkov@chromium.org
Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=174019
Patch Set 1 #
Created: 6 years, 7 months ago
Messages
Total messages: 6 (0 generated)
|