mirror of
https://github.com/d0k3/GodMode9.git
synced 2025-06-26 21:52:48 +00:00
Keep RAMdrive mounted when unmounting SD
This commit is contained in:
parent
8a65f79712
commit
89cca90447
@ -38,7 +38,7 @@ bool InitExtFS() {
|
|||||||
snprintf(fsname, 7, "%lu:", i);
|
snprintf(fsname, 7, "%lu:", i);
|
||||||
fs_mounted[i] = (f_mount(fs + i, fsname, 1) == FR_OK);
|
fs_mounted[i] = (f_mount(fs + i, fsname, 1) == FR_OK);
|
||||||
if ((i == 7) && !fs_mounted[7] && (GetMountState() == IMG_RAMDRV)) {
|
if ((i == 7) && !fs_mounted[7] && (GetMountState() == IMG_RAMDRV)) {
|
||||||
f_mkfs("7:", 0, 0); // format ramdrive
|
f_mkfs("7:", 0, 0); // format ramdrive if required
|
||||||
f_mount(NULL, fsname, 1);
|
f_mount(NULL, fsname, 1);
|
||||||
fs_mounted[7] = (f_mount(fs + 7, "7:", 1) == FR_OK);
|
fs_mounted[7] = (f_mount(fs + 7, "7:", 1) == FR_OK);
|
||||||
}
|
}
|
||||||
|
@ -408,7 +408,8 @@ u32 GodMode() {
|
|||||||
}
|
}
|
||||||
} else if (switched && (pad_state & BUTTON_B)) { // unmount SD card
|
} else if (switched && (pad_state & BUTTON_B)) { // unmount SD card
|
||||||
DeinitExtFS();
|
DeinitExtFS();
|
||||||
MountImage(NULL);
|
if (GetMountState() != IMG_RAMDRV)
|
||||||
|
MountImage(NULL);
|
||||||
DeinitSDCardFS();
|
DeinitSDCardFS();
|
||||||
clipboard->n_entries = 0;
|
clipboard->n_entries = 0;
|
||||||
memset(panedata, 0x00, N_PANES * sizeof(PaneData));
|
memset(panedata, 0x00, N_PANES * sizeof(PaneData));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user