Removed unnecessary ByteBuffer allocation