Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4517529

(ref) ref to Reference subclass object is garbage collected NullPoint check..

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P3
    • Resolution: Cannot Reproduce
    • Affects Version/s: 1.4.0
    • Fix Version/s: None
    • Component/s: core-libs
    • Labels:
      None
    • Subcomponent:
    • CPU:
      unknown
    • OS:
      windows_nt

      Description

      In my module in Netbeans project (www.netbeans.org) I have the following piece of code:
      public boolean isImportant(String name) {
        Reference rf = findReference(name);
        if (rf != null) {
          CacheReference ref = (CacheReference)rf;
          return ref.isImporant();
        }
      }

      I've received a bug report (please see: http://javacvs.netbeans.org/issues/show_bug.cgi?id=16422 )
      that under the jdk1.4beta2 this piece of code throws a NPE (sometimes, not regularly) it seems like the ref is null, even when I checked it for that value..

      any ideas what might be wrong? The reporter states that it doesn't happen under jdk1.3..

      thanks..

        Attachments

          Activity

            People

            Assignee:
            mr Mark Reinhold
            Reporter:
            duke J. Duke (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: