OSDN Git Service

Experimental: verify cached constructors before use.
authorMathew Inwood <mathewi@google.com>
Thu, 31 Dec 2015 12:28:54 +0000 (12:28 +0000)
committerMathew Inwood <mathewi@google.com>
Thu, 31 Dec 2015 12:32:40 +0000 (12:32 +0000)
commit4985c5c782661c2fd0ae6c368062b5203222c087
treee0146bf0ffa1e67eb42e96da825415855a0b2c41
parentb42701047ab86a0539bdd3970f71858573fe10ec
Experimental: verify cached constructors before use.

Caching constructors can cause problems for dynamically loaded code if
the same class name appears in more than on classloader. Before using
cached constructors, verifty that they come from a valid classloader, i.e.
one that appears in the classloader chain of the current contexts
classloader. Remove ones that do not from the map to allow the associated
classes to be unloaded in case they're no longer in use.

Bug: 21690610
Change-Id: I84f2894cd03a5dc0c33aed9cd710e4a1f6d9515f
core/java/android/view/LayoutInflater.java