Restore ISO9660 filesystem non-writable error checks from "TempleOSCD_2017-05-21T03 56 09.ISO".

This commit is contained in:
TomAwezome 2022-04-16 15:53:14 -04:00
parent aa911b9a0f
commit 7d80592aaa
6 changed files with 31 additions and 2 deletions

View file

@ -141,6 +141,10 @@ I64 ClusBlkWrite(CDrive *drive, U8 *buf, I64 c, I64 blks)
}
break;
case FSt_ISO9660:
PrintErr("File System Not Writable\n");
throw('Drive');
default:
throw('Drive');
}
@ -178,6 +182,11 @@ I64 ClusAlloc(CDrive *drive, I64 c=0, I64 count=1, Bool contiguous=FALSE)
else
return FAT32AllocClus(drive, c, count);
case FSt_ISO9660:
PrintErr("File System Not Writable\n");
throw('Drive');
default:
throw('Drive');
}

View file

@ -113,6 +113,10 @@ I64 Del(U8 *files_find_mask, Bool make_mask=FALSE, Bool del_dir=FALSE, Bool prin
res = FAT32FilesDel(dirc->drive, Fs->cur_dir, dirc->mask, 0, del_dir, print_message);
break;
case FSt_ISO9660:
PrintErr("File System Not Writable\n");
break;
default:
PrintErr("File System Not Supported\n");
}

View file

@ -8,6 +8,10 @@ Bool DirNew(CDrive *drive, U8 *cur_dir, CDirEntry *tmpde, Bool free_old_chain=TR
case FSt_FAT32:
return FAT32DirNew(drive, cur_dir, tmpde, free_old_chain);
case FSt_ISO9660:
PrintErr("File System Not Writable\n");
return FALSE;
default:
PrintErr("File System Not Supported\n");
return FALSE;

View file

@ -69,7 +69,7 @@ Bool Cd(U8 *dirname=NULL, Bool make_dirs=FALSE)
res = RedSeaCd(buf, cur_dir_clus);
break;
case FSt_ISO9660:
res = ISOCd(buf,cur_dir_clus);
res = ISOCd(buf, cur_dir_clus);
break;
case FSt_FAT32:
res = FAT32Cd(buf, cur_dir_clus);
@ -153,7 +153,7 @@ I64 Dir(U8 *files_find_mask, Bool full)
"$$MA,T=\"Directory\",LM=\"PopUpCd;Dir;\n\"$$ of %s\n", st;
if (full)
"__DATE__ __TIME__ %*ts %*ts\n", csize, "SIZE", c, "BLK";
"__DATE__ __TIME__ %*ts %*ts\n", csize, "SIZE", c, "CLUS";
else
"DATE_ TIME_ %*ts\n", csize, "SIZE";
while (tmpde1)
@ -212,6 +212,10 @@ Bool DirMake(U8 *filename, I64 entry_count=0)
res = FAT32MkDir(dirc->drive, Fs->cur_dir, name, entry_count);
break;
case FSt_ISO9660:
PrintErr("File System Not Writable\n");
break;
default:
PrintErr("File System Not Supported\n");
}

View file

@ -103,6 +103,10 @@ I64 FileWrite(U8 *filename, U8 *fbuf, I64 size, CDate cdt=0, I64 attr=0)
c = FAT32FileWrite(dirc->drive, Fs->cur_dir, dirc->mask, fbuf, size, cdt, attr);
break;
case FSt_ISO9660:
PrintErr("File System Not Writable\n");
break;
default:
PrintErr("File System Not Supported\n");
}

View file

@ -37,6 +37,10 @@ Bool DriveTypeSet(U8 drv_let, I64 type=FSt_REDSEA)
mbr.p[i].type = MBR_PT_FAT32a;
break;
case FSt_ISO9660:
PrintErr("File System Not Writable\n");
throw('Drive');
default:
throw('Drive');
}