Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
-
None
Description
In the trunk, BlockDisk.write(long, byte[]) is as follows:
private boolean write( long position, byte[] data ) throws IOException { ByteBuffer buffer = ByteBuffer.allocate(HEADER_SIZE_BYTES + data.length); buffer.putInt(data.length); buffer.put(data); buffer.flip(); int written = fc.write(buffer, position); fc.force(true); return written == data.length; }
where the return statement should be:
return written == data.length + HEADER_SIZE_BYTES;