Uploaded image for project: 'Jackrabbit Content Repository'
  1. Jackrabbit Content Repository
  2. JCR-420

NullPointerException when deleting a property of type REFERENCE

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Blocker
    • Resolution: Fixed
    • 1.0
    • 1.0.1
    • jackrabbit-jcr-rmi
    • None

    Description

      In method org.apache.jackrabbit.rmi.value.SerialValueFactory#createValue a NPE is thrown when parameter value is null.

      Solution:

      Change:

      public final Value createValue(Node value) throws RepositoryException

      { return createValue(value.getUUID(), PropertyType.REFERENCE); }

      to

      public final Value createValue(Node value) throws RepositoryException {
      if (value == null)

      { return null; }

      return createValue(value.getUUID(), PropertyType.REFERENCE);
      }

      Attachments

        Activity

          People

            jukkaz Jukka Zitting
            frericksm Michael Frericks
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: