Skip to content
Commit 6d06825a authored by Henrik Engström's avatar Henrik Engström Committed by Johan Redestig
Browse files

Fix for infinite loop in RemoteViewsAdapter

This patch fixes an error in RemoteViewsAdapter when there is only one
view in the cache, and it is bigger than the cache size threshold. This
would cause the cleanup of the cache to get stuck in an infinite loop
while holding the mCache lock that is also needed by for example
getView which is called on the UI thread, leading to ANRs. This patch
breaks the loop when it sees that it can not remove the next view up
for removal.

Change-Id: I331259bb10eae9fe91e5112102e08f49cc078a1b
parent 38fcaf40
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