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

files might be closed by multiple threads (unix)

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Won't Fix
    • Affects Version/s: 11
    • Fix Version/s: None
    • Component/s: core-libs
    • Labels:
      None

      Description

      io_util_md.c fileClose can close the wrong file.

      If two threads enter this function, both might try to close the same file descriptor. This is dangerous, as the OS may have already reused the file descriptor after the first close for a third thread. We see this in our JRuby tests (the double close, not the bad case with the third thread).

      Won't fix, see Thomas' comments.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                goetz Goetz Lindenmaier
                Reporter:
                goetz Goetz Lindenmaier
              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: