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

Use try-with-resources where feasible

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: internal
    • Fix Version/s: internal
    • Component/s: tools
    • Labels:

      Description

      There are several places in jpackage where we do I/O with explicit calls to close the stream. Several of them are even missing try-finally blocks. We should modify as many of these as is feasible to use try-with-resources so the code will be more robust.

      A partial list of classes that could be fixed includes:

      IOUtils, LinuxAppImageBuilder, LinuxDebBundler, LinuxRpmBundler, MacAppImageBuilder, etc.

        Attachments

          Activity

            People

            • Assignee:
              herrick Andy Herrick
              Reporter:
              kcr Kevin Rushforth
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: