From 297bc2ec1bc487fc16684edb4d28994585a6b8b6 Mon Sep 17 00:00:00 2001 From: d0k3 Date: Mon, 30 May 2016 16:17:09 +0200 Subject: [PATCH] Fix write permissions when RAMdrive is mounted --- source/fs.c | 2 +- source/godmode.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/source/fs.c b/source/fs.c index 3b97ed2..9a243d6 100644 --- a/source/fs.c +++ b/source/fs.c @@ -86,7 +86,7 @@ bool CheckWritePermissions(const char* path) { if (pdrv == 0) { perm = PERM_SDCARD; snprintf(area_name, 16, "the SD card"); - } else if (GetMountState() == IMG_RAMDRV) { + } else if ((pdrv == 7) && (GetMountState() == IMG_RAMDRV)) { perm = PERM_RAMDRIVE; snprintf(area_name, 16, "the RAM drive"); } else if (((pdrv >= 1) && (pdrv <= 3)) || (GetVirtualSource(path) == VRT_SYSNAND)) { diff --git a/source/godmode.c b/source/godmode.c index 75a6075..6f5702b 100644 --- a/source/godmode.c +++ b/source/godmode.c @@ -7,7 +7,7 @@ #include "virtual.h" #include "image.h" -#define VERSION "0.5.0" +#define VERSION "0.5.1" #define N_PANES 2 #define IMG_DRV "789I"