fsck_msdosfs: Adjust a check.
The on-disk FAT array does not include anything before CLUST_FIRST, compensate in size check. Obtained from: NetBSD (CVS Rev. 1.20) MFC after: 2 weeks
This commit is contained in:
parent
79ccc589d2
commit
dd3f00cbaf
@ -221,7 +221,7 @@ readboot(int dosfs, struct bootblock *boot)
|
||||
break;
|
||||
}
|
||||
|
||||
if (boot->NumFatEntries < boot->NumClusters) {
|
||||
if (boot->NumFatEntries < boot->NumClusters - CLUST_FIRST) {
|
||||
pfatal("FAT size too small, %u entries won't fit into %u sectors\n",
|
||||
boot->NumClusters, boot->FATsecs);
|
||||
return FSFATAL;
|
||||
|
Loading…
Reference in New Issue
Block a user