Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.8.2
    • Fix Version/s: None
    • Component/s: XmpBox
    • Labels:
    • Environment:
      any

      Description

      The problem appears in version 1.8.2 and in revision 1493964. I
      attached a two-line patch that fixes it. This problem and the
      attached patch are similar the previously fixed PDFBOX-1456,
      PDFBOX-1457, and PDFBOX-1583, and their patches.

      In method "org.apache.xmpbox.schema.XMPSchema.merge", the loops over
      "itNewValues" and "itActualEmbeddedProperties" should break
      immediately after "alreadyPresent" is set to "true". All the
      iterations after "alreadyPresent" is set to "true" do not perform any
      useful work because the only side effect is:
      "((ArrayProperty)tmpEmbeddedProperty).getContainer().addProperty(tmpNewValue);",
      which is executed only when "if (!alreadyPresent)" is "true", i.e., it
      is never executed once "alreadyPresent" is set to "true" because
      "alreadyPresent" cannot become "false" again.

        Attachments

        1. patch.diff
          1 kB
          Adrian Nistor

          Activity

            People

            • Assignee:
              gbm.bailleul Guillaume Bailleul
              Reporter:
              adriannistor Adrian Nistor
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: