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

JS Object builtin prototype is not thread safe

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P2 P2
    • 8
    • 8
    • core-libs
    • b96
    • generic
    • generic
    • Verified

      I have been chasing a failure that occurs very very rarely (twice since I started to work on npm few weeks ago).

      Concurrent call to Object.create in parallel with object instantiation makes the PropertyListenerManager of the builtin Object prototype to :
      1) handle removeNotificationListener when Object.create is called
      2) handle addNotificationListener for object literal.

      This is causing java.util.ConcurrentModificationException

      The list of listeners should be synchronized.

        1. fix.patch
          1.0 kB
          Jean-Francois Denise
        2. thread.js
          0.5 kB
          Jean-Francois Denise

            hannesw Hannes Wallnoefer
            jfdenise Jean-Francois Denise (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: