Uploaded image for project: 'EJB 3.0'
  1. EJB 3.0
  2. EJBTHREE-1694

FieldBeanProperty.set has potential NPE, not considering Bootstrap CL

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 1.1.0
    • None
    • core
    • None

      This bit:

      ClassLoader fieldLoader = field.getType().getClassLoader();
      ClassLoader valueLoader = value.getClass().getClassLoader();
      boolean equalLoaders = fieldLoader.equals(valueLoader);

      does not consider that the bootstrap ClassLoader may be represented as null by Class.getClassLoader in some JDK impls. Results in NPE.

              arubinge@redhat.com Andrew Rubinger (Inactive)
              arubinge@redhat.com Andrew Rubinger (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Created:
                Updated:
                Resolved: