Details

    • Subcomponent:
    • Resolved In Build:
      b102
    • Verification:
      Not verified

      Backports

        Description

        The Doclet works for large numbers of source files, but fails with below NPE when apparently unremarkable source files are included.

        [javadoc] 1 error
          [javadoc] 153 warnings
          [javadoc] java.lang.NullPointerException
          [javadoc] at com.sun.tools.doclets.internal.toolkit.util.VisibleMemberMap.purgeMemberLevelMap(VisibleMemberMap.java:253)
          [javadoc] at com.sun.tools.doclets.internal.toolkit.util.VisibleMemberMap.access$300(VisibleMemberMap.java:49)
          [javadoc] at com.sun.tools.doclets.internal.toolkit.util.VisibleMemberMap$ClassMembers.<init>(VisibleMemberMap.java:325)
          [javadoc] at com.sun.tools.doclets.internal.toolkit.util.VisibleMemberMap$ClassMembers.mapClass(VisibleMemberMap.java:350)
          [javadoc] at com.sun.tools.doclets.internal.toolkit.util.VisibleMemberMap$ClassMembers.mapClass(VisibleMemberMap.java:351)
          [javadoc] at com.sun.tools.doclets.internal.toolkit.util.VisibleMemberMap$ClassMembers.build(VisibleMemberMap.java:341)
          [javadoc] at com.sun.tools.doclets.internal.toolkit.util.VisibleMemberMap$ClassMembers.access$100(VisibleMemberMap.java:291)
          [javadoc] at com.sun.tools.doclets.internal.toolkit.util.VisibleMemberMap.<init>(VisibleMemberMap.java:127)
          [javadoc] at ...

          Activity

          Hide
          jjg Jonathan Gibbons added a comment -
          This should be fixed in JDK 9 and backported.
          Show
          jjg Jonathan Gibbons added a comment - This should be fixed in JDK 9 and backported.
          Hide
          jjg Jonathan Gibbons added a comment -
          (The engineer who would normally handle this is on vacation.)
          I'll fix it in 9.
          Show
          jjg Jonathan Gibbons added a comment - (The engineer who would normally handle this is on vacation.) I'll fix it in 9.
          Hide
          jjg Jonathan Gibbons added a comment -
          Proposed change:

          $ hg tdiff
          [/w/jjg/work/dev]:

          [/w/jjg/work/dev/corba]:

          [/w/jjg/work/dev/hotspot]:

          [/w/jjg/work/dev/jaxp]:

          [/w/jjg/work/dev/jaxws]:

          [/w/jjg/work/dev/jdk]:

          [/w/jjg/work/dev/langtools]:
          diff -r 70fe7cf1ac65 src/jdk.javadoc/share/classes/com/sun/tools/doclets/internal/toolkit/util/VisibleMemberMap.java
          --- a/src/jdk.javadoc/share/classes/com/sun/tools/doclets/internal/toolkit/util/VisibleMemberMap.java Mon Jan 11 19:32:36 2016 -0800
          +++ b/src/jdk.javadoc/share/classes/com/sun/tools/doclets/internal/toolkit/util/VisibleMemberMap.java Tue Jan 12 14:20:29 2016 -0800
          @@ -248,7 +248,7 @@
                   for (ProgramElementDoc element : list) {
                       Object key = getMemberKey(element);
                       Map<ProgramElementDoc, String> memberLevelMap = memberNameMap.get(key);
          - if (level.equals(memberLevelMap.get(element)))
          + if (memberLevelMap != null && level.equals(memberLevelMap.get(element)))
                           memberLevelMap.remove(element);
                   }
               }

          Show
          jjg Jonathan Gibbons added a comment - Proposed change: $ hg tdiff [/w/jjg/work/dev]: [/w/jjg/work/dev/corba]: [/w/jjg/work/dev/hotspot]: [/w/jjg/work/dev/jaxp]: [/w/jjg/work/dev/jaxws]: [/w/jjg/work/dev/jdk]: [/w/jjg/work/dev/langtools]: diff -r 70fe7cf1ac65 src/jdk.javadoc/share/classes/com/sun/tools/doclets/internal/toolkit/util/VisibleMemberMap.java --- a/src/jdk.javadoc/share/classes/com/sun/tools/doclets/internal/toolkit/util/VisibleMemberMap.java Mon Jan 11 19:32:36 2016 -0800 +++ b/src/jdk.javadoc/share/classes/com/sun/tools/doclets/internal/toolkit/util/VisibleMemberMap.java Tue Jan 12 14:20:29 2016 -0800 @@ -248,7 +248,7 @@          for (ProgramElementDoc element : list) {              Object key = getMemberKey(element);              Map<ProgramElementDoc, String> memberLevelMap = memberNameMap.get(key); - if (level.equals(memberLevelMap.get(element))) + if (memberLevelMap != null && level.equals(memberLevelMap.get(element)))                  memberLevelMap.remove(element);          }      }
          Hide
          hgupdate HG Updates added a comment -
          URL: http://hg.openjdk.java.net/jdk9/dev/langtools/rev/3eceb9bbbb9a
          User: jjg
          Date: 2016-01-12 23:07:54 +0000
          Show
          hgupdate HG Updates added a comment - URL: http://hg.openjdk.java.net/jdk9/dev/langtools/rev/3eceb9bbbb9a User: jjg Date: 2016-01-12 23:07:54 +0000
          Hide
          hgupdate HG Updates added a comment -
          URL: http://hg.openjdk.java.net/jdk9/jdk9/langtools/rev/3eceb9bbbb9a
          User: lana
          Date: 2016-01-20 20:50:56 +0000
          Show
          hgupdate HG Updates added a comment - URL: http://hg.openjdk.java.net/jdk9/jdk9/langtools/rev/3eceb9bbbb9a User: lana Date: 2016-01-20 20:50:56 +0000

            People

            • Assignee:
              jjg Jonathan Gibbons
              Reporter:
              shadowbug Shadow Bug
            • Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: