Currently, the RegionFile
(line 52) class extends the file if it's size is not a multiple of 4KB, but does it in a inefficient way:
for(int i = 0; i < (this.file.length() & 0xfff); i++) {
this.file.write(0);
}
That code could potentially cause up to 4095
file extensions, when we could just do them at once with the following code: