/** * Writes the specified block to disk and resets the dirty flag. * * @param bf buffer to write * @throws IOException I/O exception */ private void writeBlock(final Buffer bf) throws IOException { file.seek(bf.pos * IO.BLOCKSIZE); file.write(bf.data); bf.dirty = false; }