Fix from Ivan Drucker: PARENT_ENTRY starts at one, not zero.

This commit is contained in:
2013-11-19 02:35:55 +00:00
parent 4989c0353b
commit 11805cd8b3
1 changed files with 1 additions and 1 deletions

View File

@ -1338,7 +1338,7 @@ public class ProdosFormatDisk extends FormattedDisk {
int blockNumber = directory.getFileEntryBlock();
while (blockNumber != 0) {
byte[] block = readBlock(blockNumber);
int entryNum = 0;
int entryNum = 1; // Beneath ProDOS says this starts at zero, but subsequent correction says it starts at 1.
int offset = 4;
while (offset+ProdosCommonEntry.ENTRY_LENGTH < BLOCK_SIZE) {
int value = AppleUtil.getUnsignedByte(block[offset]);