Qpid
  1. Qpid
  2. QPID-2744

FieldTable throws a NullPointerException in setObjectProperty rather than expected AMQPInvalidClassException

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: M2, M2.1, M3, M4, 0.5, 0.6
    • Fix Version/s: 0.7
    • Component/s: Java Common
    • Labels:
      None

      Description

      When a null object is passed to setObjectProperty in the FieldTable we should throw an AMQPInvalidClassException stating we need a primitive value.

      However we do object.getClass() to show what we were given.. if object is null then we get a NPE.

      This needs to be fixed so it doesn't NPE.

        Activity

        Hide
        Andrew Kennedy added a comment -

        Committed changes fix this issue

        Show
        Andrew Kennedy added a comment - Committed changes fix this issue
        Hide
        Andrew Kennedy added a comment -

        Added fix for 0-10 code path. This means relaxing the error checks on the thrown MessageFormatException in the test, possibly this should be fixed to make both code paths do the same thing?

        Show
        Andrew Kennedy added a comment - Added fix for 0-10 code path. This means relaxing the error checks on the thrown MessageFormatException in the test, possibly this should be fixed to make both code paths do the same thing?

          People

          • Assignee:
            Martin Ritchie
            Reporter:
            Martin Ritchie
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development