mirror of https://github.com/apache/activemq.git
Remove unnecessary buffer initialization after confirmation that it is not needed.
This commit is contained in:
parent
edfc23ee9d
commit
5e0f49332b
|
@ -279,12 +279,7 @@ public class Journal {
|
|||
|
||||
private void doPreallocationZeros(RecoverableRandomAccessFile file) {
|
||||
ByteBuffer buffer = ByteBuffer.allocate(maxFileLength);
|
||||
// intentional double initialization due to interaction with the OS level
|
||||
// file allocation mechanics.
|
||||
for (int i = 0; i < maxFileLength; i++) {
|
||||
buffer.put((byte) 0x00);
|
||||
}
|
||||
buffer.flip();
|
||||
buffer.limit(maxFileLength);
|
||||
|
||||
try {
|
||||
FileChannel channel = file.getChannel();
|
||||
|
|
Loading…
Reference in New Issue