Skip to content
Commit 217ae4e9 authored by Kevin's avatar Kevin
Browse files

Solve inflated view/cached view inconsistency

In a specific race condition where we free a view and clear its cached
view while that view is reinflating, we get into a scenario where the
view is null but we still have a cached view. This causes a crash if you
then try to reinflate the view. This occurs because the reinflate
updates the cache but does not update the view

In this CL, we tightly couple updates to the view in inflation so that
they always update the cache together. This way, it shouldn't be
possible for the inflated view and cached view to get out of sync.

Bug: 124387005
Test: Reproduced bug (via artificially increasing reapplyAsync latency)
and it no longer crashes.
Change-Id: Icfad13d00922d04213147fdaedb1229ab73b133c
parent b4264999
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment