From 4d8c0332032dc4ad31a9a8ebd56f821ee92bc894 Mon Sep 17 00:00:00 2001 From: Koushik Dutta Date: Thu, 9 Jun 2011 14:19:04 -0700 Subject: [PATCH 1/2] also fix up the /sdcard symlink on startup Change-Id: Ie7647b3fbb2543761d59b8c33ceeea36e3221c32 --- recovery.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/recovery.c b/recovery.c index 09a7b7f..51b5366 100644 --- a/recovery.c +++ b/recovery.c @@ -795,7 +795,11 @@ main(int argc, char **argv) { return busybox_driver(argc, argv); } __system("/sbin/postrecoveryboot.sh"); - + if (volume_for_path("/sdcard") == NULL) { + rmdir("/sdcard"); + symlink("/data/media", "/sdcard"); + } + int is_user_initiated_recovery = 0; time_t start = time(NULL); From 14d9e755778d07eb3b990355f9d4c0e426fb2997 Mon Sep 17 00:00:00 2001 From: j_r0dd Date: Thu, 9 Jun 2011 18:37:28 -0400 Subject: [PATCH 2/2] added the efs partition to the do not format list since this holds the imei info. Change-Id: I2644327c1dbaa63420b7eb7b1bce10377c0e0837 --- extendedcommands.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extendedcommands.c b/extendedcommands.c index 5543e96..9439739 100644 --- a/extendedcommands.c +++ b/extendedcommands.c @@ -500,7 +500,7 @@ int is_safe_to_format(char* name) { char str[255]; char* partition; - property_get("ro.cwm.forbid_format", str, "/misc,/radio,/bootloader,/recovery"); + property_get("ro.cwm.forbid_format", str, "/misc,/radio,/bootloader,/recovery,/efs"); partition = strtok(str, ", "); while (partition != NULL) {