Uploaded image for project: 'PDFBox'
  1. PDFBox
  2. PDFBOX-5594

Remove finalize from TrueTypeFont

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.0.0 PDFBox
    • 3.0.0 PDFBox
    • FontBox
    • None

    Description

      The usage of finalize is discouraged so that it is a good idea to remove it.

      I've found a way to do so for org.apache.fontbox.ttf.TrueTypeFont.

      All the data of a RandomAccessReadDataStream is copied to a final byte array. The additional RandomAccessReadBuffer isn't needed at all, so that it is save to do nothing when closing a RandomAccessReadDataStream. Now it is save to remove the finalize override from TrueTypeFont

      Attachments

        Activity

          People

            lehmi Andreas Lehmkühler
            lehmi Andreas Lehmkühler
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: