JDK-8007393 : Possible race condition after JDK-6664509
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.util.logging
  • Affected Version: 7u13
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • OS: other
  • CPU: other
  • Submitted: 2013-02-01
  • Updated: 2013-07-31
  • Resolved: 2013-02-07
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
Other JDK 6 JDK 7 JDK 8 Other
1.4.2_42,OpenJDK6Fixed 6u41Fixed 7u15Fixed 8 b02Fixed OpenJDK6Fixed
Description
On 2/1/13 8:11 AM, Mandy Chung wrote:

By code inspection, however, I concur that there is a timing race there that a logger can
be GC'ed where a logger exists where being queried and immediately being gc'ed after that.
I don't think Licensee's proposed 1-line fix is a completed fix though.

LogManager.java L 633-635
            if (!manager.addLogger(result) && result.getHandlers().length == 0) {
                // if logger already exists but handlers not set
                final Logger l = manager.getLogger(name);
                final Logger logger = result;
Comments
Reporter (Licensee) has confirmed the patch on their port.
05-02-2013

SA review: http://sa.sfbay.sun.com/mail-archive/8007393-cpu-review/ Webrev: http://sa.sfbay.sun.com/projects/cpu-review_data/7u15/8007393/ Reviewed-by: alanb, jgish Verification done: core regression tests on all platforms. JCK tests on solaris-i586.
01-02-2013