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

NotificationBroadcasterSupport should not use synchronized(this)

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: 5.0
    • Fix Version/s: 5.0u1
    • Component/s: core-svc
    • Labels:

      Backports

        Description

        NotificationBroadcasterSupport controls concurrent access to its internal list of listeners by using synchronized (this). This is a bad idea since this class is intended to be subclassed. If the subclass also does synchronized (this), or equivalently has synchronized methods, then unexpected deadlocks can arise.

          Attachments

            Issue Links

              Activity

                People

                Assignee:
                emcmanus Eamonn McManus
                Reporter:
                emcmanus Eamonn McManus
                Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                  Dates

                  Created:
                  Updated:
                  Resolved:
                  Imported:
                  Indexed: