98bf12f99989ba2550fac83ee48ecbb6f1582f07 |
|
26-May-2016 |
Jeff Sharkey <jsharkey@android.com> |
Release AssetManagers when ejecting storage. When ejecting a storage device, the system process needs to rapidly release any open FDs to prevent itself from being killed by vold. This change examines all ResourceImpls cached inside the system process and evicts any that reference the storage device being ejected. (ResourcesManager will gladly recreate any evicted entries when asked again in the future.) Also replace broken use of WeakHashMap, since we want the values to be weak references, not the keys. Bug: 28867548 Change-Id: Ib9cfc66497149b6d3f8d49213e9779408a331d2a
/frameworks/base/services/core/java/com/android/server/AttributeCache.java
|