diff options
author | Andy McFadden <fadden@android.com> | 2012-01-23 09:48:53 -0800 |
---|---|---|
committer | Andy McFadden <fadden@android.com> | 2012-01-23 09:51:42 -0800 |
commit | dc7bf5d8bff86bed7947806c81a28aff5e9a8c3e (patch) | |
tree | 6fe2e18a1eeb03bc922bbfe9bf9ea2eab6ec6d0d /core | |
parent | 30f1312b3cb584c14eba60e6809d4eeed5d906bf (diff) | |
download | frameworks_base-dc7bf5d8bff86bed7947806c81a28aff5e9a8c3e.zip frameworks_base-dc7bf5d8bff86bed7947806c81a28aff5e9a8c3e.tar.gz frameworks_base-dc7bf5d8bff86bed7947806c81a28aff5e9a8c3e.tar.bz2 |
Don't use bootstrap loader directly
The VM is allowed to use null to represent the bootstrap class
loader, so attempting to call methods on it is a bad idea. Use
the system class loader instead.
Change-Id: I9190848945f679d546d5fb30aba10fd27c7e5404
Diffstat (limited to 'core')
-rw-r--r-- | core/java/com/android/internal/os/ZygoteInit.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/java/com/android/internal/os/ZygoteInit.java b/core/java/com/android/internal/os/ZygoteInit.java index 9c45dc6..6a99a2b 100644 --- a/core/java/com/android/internal/os/ZygoteInit.java +++ b/core/java/com/android/internal/os/ZygoteInit.java @@ -243,7 +243,7 @@ public class ZygoteInit { private static void preloadClasses() { final VMRuntime runtime = VMRuntime.getRuntime(); - InputStream is = ZygoteInit.class.getClassLoader().getResourceAsStream( + InputStream is = ClassLoader.getSystemClassLoader().getResourceAsStream( PRELOADED_CLASSES); if (is == null) { Log.e(TAG, "Couldn't find " + PRELOADED_CLASSES + "."); |