diff options
Diffstat (limited to 'bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/loader/buddy/SystemPolicy.java')
-rw-r--r-- | bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/loader/buddy/SystemPolicy.java | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/loader/buddy/SystemPolicy.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/loader/buddy/SystemPolicy.java index 859837657..7edefe1af 100644 --- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/loader/buddy/SystemPolicy.java +++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/loader/buddy/SystemPolicy.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2005, 2012 IBM Corporation and others. + * Copyright (c) 2005, 2016 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -15,15 +15,10 @@ import java.net.URL; import java.security.AccessController; import java.security.PrivilegedAction; import java.util.Enumeration; +import org.eclipse.osgi.internal.framework.EquinoxContainerAdaptor; public class SystemPolicy implements IBuddyPolicy { - private static class ParentClassLoader extends ClassLoader { - protected ParentClassLoader() { - super(Object.class.getClassLoader()); - } - } - public static final byte BOOT = 0; public static final byte EXT = 1; public static final byte APP = 2; @@ -57,15 +52,15 @@ public class SystemPolicy implements IBuddyPolicy { case APP : if (ClassLoader.getSystemClassLoader() != null) return ClassLoader.getSystemClassLoader(); - return new ParentClassLoader(); + return EquinoxContainerAdaptor.BOOT_CLASSLOADER; case BOOT : - return new ParentClassLoader(); + return EquinoxContainerAdaptor.BOOT_CLASSLOADER; case EXT : if (ClassLoader.getSystemClassLoader() != null) return ClassLoader.getSystemClassLoader().getParent(); - return new ParentClassLoader(); + return EquinoxContainerAdaptor.BOOT_CLASSLOADER; } return null; } |