From 213ef7f367e2b22d206127952d5c99870b2b913e Mon Sep 17 00:00:00 2001 From: Mateusz Faderewski Date: Fri, 28 Jul 2023 21:29:12 +0200 Subject: [PATCH] SC64 load file path cleanup --- src/flashcart/sc64/sc64.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/flashcart/sc64/sc64.c b/src/flashcart/sc64/sc64.c index 23d9477c..b091f7f8 100644 --- a/src/flashcart/sc64/sc64.c +++ b/src/flashcart/sc64/sc64.c @@ -104,9 +104,6 @@ static flashcart_error_t sc64_init (void) { } static flashcart_error_t sc64_deinit (void) { - // NOTE: Necessary because libcart enables ROM write by default - sc64_set_config(CFG_ROM_WRITE_ENABLE, false); - sc64_lock(); return FLASHCART_OK; @@ -116,7 +113,7 @@ static flashcart_error_t sc64_load_rom (char *rom_path) { FIL fil; UINT br; - if (f_open(&fil, rom_path, FA_READ) != FR_OK) { + if (f_open(&fil, strip_sd_prefix(rom_path), FA_READ) != FR_OK) { return FLASHCART_ERROR_LOAD; } @@ -214,7 +211,7 @@ static flashcart_error_t sc64_load_save (char *save_path) { FIL fil; UINT br; - if (f_open(&fil, save_path, FA_READ) != FR_OK) { + if (f_open(&fil, strip_sd_prefix(save_path), FA_READ) != FR_OK) { return FLASHCART_ERROR_LOAD; }