NPE for the package which don't have any constant value
Jonathan Gibbons
jonathan.gibbons at oracle.com
Wed Apr 1 23:26:19 UTC 2015
Thanks,
It looks like Bhavesh will take it from here.
-- Jon
On 04/01/2015 02:32 PM, ShinyaYoshida wrote:
> Hi Jon,
> I've just filed this issue.
> Thank you for your advice.
>
> https://bugs.openjdk.java.net/browse/JDK-8076513
>
>
> 2015-04-02 6:19 GMT+09:00 Jonathan Gibbons
> <jonathan.gibbons at oracle.com <mailto:jonathan.gibbons at oracle.com>>:
>
> Hi Shinya,
>
> I checked with the admin folk, and you should be able to file an
> entry for this in bugs.openjdk.java.net
> <http://bugs.openjdk.java.net>, and then, submit an official
> contribution.
>
> -- Jon
>
>
>
> On 04/01/2015 02:08 PM, ShinyaYoshida wrote:
>
> Hi,
> I found NPE for the package which don't have any constant value:
>
> /tmp/test/Test.java
> package test;
> public class Test
> {
> // there is no constant value in test packages
> }
>
> $ /PATH_TO_JAVADOC_NEXT_JDK_IMAGE/bin/javadoc -html5
> -sourcepath /tmp test
>
> Loading source files for package test...
> Constructing Javadoc information...
> Standard Doclet version 1.8.0
> Building tree for all the packages and classes...
> Generating /tmp/javadoc/test/Test.html...
> Generating /tmp/javadoc/test/package-frame.html...
> Generating /tmp/javadoc/test/package-summary.html...
> Generating /tmp/javadoc/test/package-tree.html...
> Generating /tmp/javadoc/constant-values.html...
> javadoc: error - java.lang.NullPointerException
> 1 error
>
> Here is the possible fix:
> diff -r 228f66693293
> src/jdk.javadoc/share/classes/com/sun/tools/doclets/formats/html/ConstantsSummaryWriterImpl.java
> ---
> a/src/jdk.javadoc/share/classes/com/sun/tools/doclets/formats/html/ConstantsSummaryWriterImpl.java
> Tue Feb 24 16:13:47 2015 -0800
> +++
> b/src/jdk.javadoc/share/classes/com/sun/tools/doclets/formats/html/ConstantsSummaryWriterImpl.java
> Thu Apr 02 06:00:24 2015 +0900
> @@ -347,7 +347,7 @@
> * {@inheritDoc}
> */
> public void addConstantSummaries(Content contentTree,
> Content
> summariesTree) {
> - if (configuration.allowTag(HtmlTag.SECTION))
> + if (configuration.allowTag(HtmlTag.SECTION) &&
> summaryTree != null)
> summariesTree.addContent(summaryTree);
> if (configuration.allowTag(HtmlTag.MAIN)) {
> mainTree.addContent(summariesTree);
>
> Regards,
> shinyafox(Shinya Yoshida)
>
>
>
More information about the javadoc-next-dev
mailing list