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

Improve thread safety of FileTime.toString and toInstant

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P5
    • 20
    • 17, 19, 20
    • core-libs
    • b10

    Description

      Class java.nio.file.attribute.FileTime is immutable with 2 fields which are initialized lazily.
      We need to read fields instant/valueAsString once, as to dodge/resolve the data race on reading lazily-initialized fields.

      Attachments

        Issue Links

          Activity

            People

              aturbanov Andrey Turbanov
              aturbanov Andrey Turbanov
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: