Uploaded image for project: 'yangtools'
  1. yangtools
  2. YANGTOOLS-180

STRING_DEFAULT_CODEC - deserialize can return null

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved
    • Resolution: Done
    • None
    • None
    • None
    • None
    • Operating System: Windows
      Platform: PC

    • 1130

    Description

      TypeDefinitionAwareCodec contains class StringCodecStringImpl where deserialize method is implemented like this:

      public String deserialize(String stringRepresentation)

      { return stringRepresentation; }

      It cause NullPointerException when trying parse from composite node to normalized node (if there is node with null value).

      Could it be like this?

      public String deserialize(String stringRepresentation)

      { return stringRepresentation == null ? "" : stringRepresentation; }

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            jgloncak Jozef Gloncak
            jgloncak Jozef Gloncak
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: