ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject DO NOT REPLY [Bug 46857] New: Thread-unsafe use of DateFormat
Date Sun, 15 Mar 2009 22:20:33 GMT

           Summary: Thread-unsafe use of DateFormat
           Product: Ant
           Version: 1.7.1
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Core

The class has static field
DATE_HEADER_FORMAT of type DateFormat. This type is unsafe for multithreaded
use (from JavaDoc: "Date formats are not synchronized. It is recommended to
create separate format instances for each thread. If multiple threads access a
format concurrently, it must be synchronized externally.")
So either method getDateFromFormat (the only one using DATE_HEADER_FORMAT)
should be synchronized or new synchronized methods for accessing
DATE_HEADER_FORMAT should be written

Configure bugmail:
------- You are receiving this mail because: -------
You are the assignee for the bug.

View raw message