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

java.beans.MethodRef#get throws NullPointerException

XMLWordPrintable

    • b133
    • x86_64
    • linux

        FULL PRODUCT VERSION :
        java version "1.8.0_92"
        Java(TM) SE Runtime Environment (build 1.8.0_92-b14)
        Java HotSpot(TM) Server VM (build 25.92-b14, mixed mode)

        ADDITIONAL OS VERSION INFORMATION :
        Linux jokimi1-vdm 3.13.0-35-generic #62-Ubuntu SMP Fri Aug 15 01:58:42 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux

        A DESCRIPTION OF THE PROBLEM :
        When this line is reached...

          "return isPackageAccessible(method.getDeclaringClass()) ? method : null;"

        ... "method" can be null.


        ERROR MESSAGES/STACK TRACES THAT OCCUR :
        Caused by: java.lang.NullPointerException
        at java.beans.MethodRef.get(MethodRef.java:72) ~[?:1.8.0_92]
        at java.beans.PropertyDescriptor.getWriteMethod(PropertyDescriptor.java:271) ~[?:1.8.0_92]
        at java.beans.Introspector.addPropertyDescriptor(Introspector.java:588) ~[?:1.8.0_92]
        at java.beans.Introspector.addPropertyDescriptors(Introspector.java:614) ~[?:1.8.0_92]
        at java.beans.Introspector.getTargetPropertyInfo(Introspector.java:467) ~[?:1.8.0_92]
        at java.beans.Introspector.getBeanInfo(Introspector.java:428) ~[?:1.8.0_92]
        at java.beans.Introspector.getBeanInfo(Introspector.java:173) ~[?:1.8.0_92]

        REPRODUCIBILITY :
        This bug can be reproduced always.

        ---------- BEGIN SOURCE ----------
        I was unable to reproduce it outside the application. I think it might be dependent on memory/GC pressure. When this happens, there is a lot of object allocation.
        ---------- END SOURCE ----------

              serb Sergey Bylokhov
              webbuggrp Webbug Group
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: