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

Improve finalisation for FileInputStream/FileOutputStream/RandomAccessFile

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: 6-pool, 7, 8
    • Fix Version/s: 8
    • Component/s: core-libs
    • Labels:
      None
    • Subcomponent:
    • Resolved In Build:
      b15
    • CPU:
      generic
    • OS:
      generic
    • Verification:
      Verified

      Backports

        Description

        Finalisation for FileInputStream/FileOutputStream/RandomAccessFile streams that share the same native FileDescritor needs improvement. Currently a counter is used to keep track of streams which reference the same native FD. A close() on one of the streams means other streams are not properly notified of the event.

        Best approach is to modify fileDescriptor so that FileInputStream/FileOutputStream/RandomAccessFile classes can register with them and ensure streams are correctly closed out at close() time or when finalizer gets to run.

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  coffeys Sean Coffey
                  Reporter:
                  coffeys Sean Coffey
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  0 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Imported:
                    Indexed: