From 8ec94187829484d925bfeb8bcf35b0ef131f0d1e Mon Sep 17 00:00:00 2001 From: Koushik Dutta Date: Mon, 21 Jun 2010 12:27:43 -0700 Subject: [PATCH] fix fstab for /sdcard --- extendedcommands.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/extendedcommands.c b/extendedcommands.c index 5b5f5a2..ad162f1 100644 --- a/extendedcommands.c +++ b/extendedcommands.c @@ -810,7 +810,14 @@ void write_fstab_root(char *root_path, FILE *file) } else { - fprintf(file, "%s ", info->device); + // only SDCARD: seems to be using device2. + // and mmcblkXp1 is the fallback/device2. + // However, generally, mmcblkXp1 is usually where the + // FAT partition is located... so favor that. + if (NULL == info->device2) + fprintf(file, "%s ", info->device); + else + fprintf(file, "%s ", info->device2); } fprintf(file, "%s ", info->mount_point);