diff options
Diffstat (limited to 'vm/reference/java/io/VMObjectInputStream.java')
-rw-r--r-- | vm/reference/java/io/VMObjectInputStream.java | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/vm/reference/java/io/VMObjectInputStream.java b/vm/reference/java/io/VMObjectInputStream.java index 5fb56fcd4..be0f8eb52 100644 --- a/vm/reference/java/io/VMObjectInputStream.java +++ b/vm/reference/java/io/VMObjectInputStream.java @@ -40,10 +40,7 @@ exception statement from your version. */ package java.io; import gnu.classpath.Configuration; -import gnu.classpath.VMStackWalker; import java.lang.reflect.Constructor; -import java.security.AccessController; -import java.security.PrivilegedAction; final class VMObjectInputStream { @@ -56,42 +53,6 @@ final class VMObjectInputStream } /** - * PrivilegedAction needed for Class.getClassLoader() - */ - private static PrivilegedAction loaderAction = new PrivilegedAction() - { - /** - * Returns the first user defined class loader on the call stack, or the - * context class loader of the current thread, when no non-null class loader - * was found. - */ - public Object run() - { - Class[] ctx = VMStackWalker.getClassContext(); - - for (int i = 0; i < ctx.length; i++) - { - ClassLoader cl = ctx[i].getClassLoader(); - if (cl != null) - return cl; - } - return Thread.currentThread().getContextClassLoader(); - } - }; - - /** - * Returns the first user defined class loader on the call stack, or the - * context class loader of the current thread, when no non-null class loader - * was found. - * - * @return the class loader - */ - static ClassLoader currentClassLoader() - { - return (ClassLoader) AccessController.doPrivileged(loaderAction); - } - - /** * Allocates a new Object of type clazz but without running the * default constructor on it. It then calls the given constructor on * it. The given constructor method comes from the constr_clazz |