JDK-6769976 : (fc) FileChannelImpl.isAMappedBufferField not used
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.nio
  • Affected Version: 7
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2008-11-11
  • Updated: 2010-05-06
  • Resolved: 2009-01-31
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 6 JDK 7
6u14Fixed 7 b46Fixed
Related Reports
Relates :  
Description
isAMappedBuffer is a static field in sun.nio.ch.FileChannelImpl initiated in the classes' static initializer but not used.

Comments
SUGGESTED FIX src/share/classes/sun/nio/ch/FileChannelImpl.java *** 58,70 **** private static final NativeDispatcher nd; // Memory allocation size for mapping buffers private static final long allocationGranularity; - // Cached field for MappedByteBuffer.isAMappedBuffer - private static final Field isAMappedBufferField; - // File descriptor private final FileDescriptor fd; // File access mode (immutable) private final boolean writable; --- 58,67 ---- *** 1313,1322 **** static { Util.load(); allocationGranularity = initIDs(); nd = new FileDispatcher(); - isAMappedBufferField = Reflect.lookupField("java.nio.MappedByteBuffer", - "isAMappedBuffer"); } } --- 1310,1317 ---
22-01-2009

EVALUATION Introduced by 4652496 in 1.4.1 and subsequently orphaned by other changes in that release.
11-11-2008