Possible synchonization issue in jdk/internal/jimage/ImageReader.java

XMLWordPrintable

    • Type: Bug
    • Resolution: Unresolved
    • Priority: P4
    • 27
    • Affects Version/s: 9, 25
    • Component/s: tools
    • None

      In the private `close()` method of SharedImageReader (called from the public `ImageReader#close()` method) the nodes cache is cleared with the `OPEN_FILES` map locked.
      However the `nodes` cache is otherwise only read/written while the `SharedImageReader` instance is locked.
      This code around this still needs to synchronize on the `OPEN_FILES` map, but I think the nodes cache should be cleared separately after unlocking the `OPEN_FILES` map and resynchronizing the shared reader.

            Assignee:
            David Beaumont
            Reporter:
            David Beaumont
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: