Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8358623

Avoid unnecessary data copying in ICC_Profile

XMLWordPrintable

    • 2d

      There are two issues in ICC_Profile related to unnecessary data copying:
      1. ICC_Profile.getInstance(byte[] data) method copies the profile header for validation. This copy appears redundant since the original data array is used later(added by the https://bugs.openjdk.org/browse/JDK-8347377).
      2. Some code use getData(icSigHead) to get the header. This method always creates a new array. it is preferable to use getData(cmmProfile(), icSigHead), to avoid the extra copy.

            serb Sergey Bylokhov
            serb Sergey Bylokhov
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: