diff options
-rw-r--r-- | org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/AjBuildManager.java | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/AjBuildManager.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/AjBuildManager.java index f3d6d89f4..0799a7784 100644 --- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/AjBuildManager.java +++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/AjBuildManager.java @@ -873,7 +873,7 @@ public class AjBuildManager implements IOutputClassFileNameProvider, IBinarySour public FileSystem getLibraryAccess(String[] classpaths, String[] filenames) { String defaultEncoding = buildConfig.getOptions().defaultEncoding; if ("".equals(defaultEncoding)) {//$NON-NLS-1$ - defaultEncoding = null; //$NON-NLS-1$ + defaultEncoding = null; } // Bug 46671: We need an array as long as the number of elements in the classpath - *even though* not every // element of the classpath is likely to be a directory. If we ensure every element of the array is set to @@ -898,7 +898,7 @@ public class AjBuildManager implements IOutputClassFileNameProvider, IBinarySour String defaultEncoding = buildConfig.getOptions().defaultEncoding; if ("".equals(defaultEncoding)) {//$NON-NLS-1$ - defaultEncoding = null; //$NON-NLS-1$ + defaultEncoding = null; } for (int i = 0; i < fileCount; i++) { @@ -971,8 +971,17 @@ public class AjBuildManager implements IOutputClassFileNameProvider, IBinarySour // cleanup org.aspectj.ajdt.internal.compiler.CompilerAdapter.setCompilerAdapterFactory(null); AnonymousClassPublisher.aspectOf().setAnonymousClassCreationListener(null); - // environment.cleanup(); - // environment = null; + if (!willReceiveAJDTCallbackForCleanup) { + environment.cleanup(); + environment = null; + } + } + + public static boolean willReceiveAJDTCallbackForCleanup = false; + + public void cleanup() { + environment.cleanup(); + environment = null; } /* |