aboutsummaryrefslogtreecommitdiff
path: root/backends/platform/ds/arm9/source/fat/gba_nds_fat.c
diff options
context:
space:
mode:
Diffstat (limited to 'backends/platform/ds/arm9/source/fat/gba_nds_fat.c')
-rw-r--r--backends/platform/ds/arm9/source/fat/gba_nds_fat.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/backends/platform/ds/arm9/source/fat/gba_nds_fat.c b/backends/platform/ds/arm9/source/fat/gba_nds_fat.c
index 46aff1ced9..5a44e2dbd9 100644
--- a/backends/platform/ds/arm9/source/fat/gba_nds_fat.c
+++ b/backends/platform/ds/arm9/source/fat/gba_nds_fat.c
@@ -818,17 +818,19 @@ bool FAT_InitFiles (void)
{
return (false);
}
-
// Read first sector of CF card
if ( !disc_ReadSector(0, globalBuffer)) {
return false;
}
+
// Make sure it is a valid MBR or boot sector
if ( (globalBuffer[0x1FE] != 0x55) || (globalBuffer[0x1FF] != 0xAA)) {
return false;
}
+
+
// Check if there is a FAT string, which indicates this is a boot sector
if ((globalBuffer[0x36] == 'F') && (globalBuffer[0x37] == 'A') && (globalBuffer[0x38] == 'T'))
{