From 065616aea18010d76a8c907f6940234d8c2ef108 Mon Sep 17 00:00:00 2001 From: Reinier Zwitserloot Date: Thu, 15 Oct 2020 23:22:00 +0200 Subject: [#2599] Completely rewrite how we decide whether it's ecj or eclipse for patching --- src/eclipseAgent/lombok/eclipse/agent/EclipseLoaderPatcher.java | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/eclipseAgent/lombok/eclipse/agent/EclipseLoaderPatcher.java') diff --git a/src/eclipseAgent/lombok/eclipse/agent/EclipseLoaderPatcher.java b/src/eclipseAgent/lombok/eclipse/agent/EclipseLoaderPatcher.java index aa01c13d..25906c6b 100644 --- a/src/eclipseAgent/lombok/eclipse/agent/EclipseLoaderPatcher.java +++ b/src/eclipseAgent/lombok/eclipse/agent/EclipseLoaderPatcher.java @@ -31,6 +31,12 @@ import lombok.patcher.scripts.ScriptBuilder; public class EclipseLoaderPatcher { private static final String TRANSPLANTS_CLASS_NAME = "lombok.eclipse.agent.EclipseLoaderPatcherTransplants"; + static final String[] OSGI_TYPES = { + "org/eclipse/osgi/internal/baseadaptor/DefaultClassLoader", + "org/eclipse/osgi/framework/adapter/core/AbstractClassLoader", + "org/eclipse/osgi/internal/loader/ModuleClassLoader" + }; + public static void patchEquinoxLoaders(ScriptManager sm, Class launchingContext) { sm.addScript(ScriptBuilder.exitEarly() .target(new MethodTarget("org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader", "loadClass", -- cgit