--- a/langtools/src/share/classes/com/sun/tools/javadoc/JavadocMemberEnter.java Fri Nov 02 19:17:03 2012 -0700
+++ b/langtools/src/share/classes/com/sun/tools/javadoc/JavadocMemberEnter.java Sat Nov 03 21:07:30 2012 -0700
@@ -81,6 +81,9 @@
docenv.makeAnnotationTypeElementDoc(meth, docComment, tree, lineMap);
else
docenv.makeMethodDoc(meth, docComment, tree, lineMap);
+
+ // release resources
+ tree.body = null;
}
@Override
--- a/langtools/src/share/classes/com/sun/tools/javadoc/Start.java Fri Nov 02 19:17:03 2012 -0700
+++ b/langtools/src/share/classes/com/sun/tools/javadoc/Start.java Sat Nov 03 21:07:30 2012 -0700
@@ -394,6 +394,9 @@
// legacy?
languageVersion == null || languageVersion == LanguageVersion.JAVA_1_1, quiet);
+ // release resources
+ comp = null;
+
// pass off control to the doclet
boolean ok = root != null;
if (ok) ok = docletInvoker.start(root);