mirror of
https://github.com/Polprzewodnikowy/N64FlashcartMenu.git
synced 2024-11-21 18:19:19 +01:00
Add additional check in fatfs_get_file_sectors
This commit is contained in:
parent
7670ffe6ba
commit
2dc83c49ed
@ -51,7 +51,7 @@ bool fatfs_get_file_sectors (char *path, uint32_t *address, address_type_t type,
|
|||||||
|
|
||||||
uint32_t cluster = fil.clust;
|
uint32_t cluster = fil.clust;
|
||||||
|
|
||||||
if (cluster >= fs->n_fatent) {
|
if ((cluster < 2) || (cluster >= fs->n_fatent)) {
|
||||||
error = true;
|
error = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user