JDK-8008650 : rotatingFileStream needs a cleanup
  • Type: Enhancement
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 9
  • Priority: P4
  • Status: Resolved
  • Resolution: Duplicate
  • Submitted: 2013-02-21
  • Updated: 2014-12-03
  • Resolved: 2014-12-03
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.
JDK 9
9Resolved
Related Reports
Duplicate :  
Description
There are a few different things in rotatingFileStream that needs a closer look and some cleanup.

1. The class has two constructors, but only one of them is used. They are identical except for a minor detail and this code duplication should be removed.

2. The class has it's own counter, _bytesWritten, instead of using the inherited counters for position. The inherited counters are updated, but it's not clear if this is done in a correct way as they are updated even though nothing is written to the log file (if file==NULL).

3. Some external code is looking at the inherited counters in their logic. Since these counters are not updated and reset properly it is not clear what happens if the counters wrap and report zero to the external logic.

Comments
Seems these issues was fixed by JDK-7164841. Closing.
03-12-2014