vold: If we're bootstrapping, don't automatically mount the SD card. Also fixes some
error display bugs (our printf doesnt support %m)

Signed-off-by: San Mehat <san@google.com>
diff --git a/vold/mmc.c b/vold/mmc.c
index 0f08964..cbddb92 100644
--- a/vold/mmc.c
+++ b/vold/mmc.c
@@ -43,7 +43,8 @@
     struct dirent *de;
 
     if (!(d = opendir(SYSFS_CLASS_MMC_PATH))) {
-        LOG_ERROR("Unable to open '%s' (%m)", SYSFS_CLASS_MMC_PATH);
+        LOG_ERROR("Unable to open '%s' (%s)", SYSFS_CLASS_MMC_PATH,
+                  strerror(errno));
         return -errno;
     }
 
@@ -54,8 +55,10 @@
             continue;
 
         sprintf(tmp, "%s/%s", SYSFS_CLASS_MMC_PATH, de->d_name);
-        if (mmc_bootstrap_controller(tmp))
-            LOG_ERROR("Error bootstrapping controller '%s' (%m)", tmp);
+        if (mmc_bootstrap_controller(tmp)) {
+            LOG_ERROR("Error bootstrapping controller '%s' (%s)", tmp,
+                      strerror(errno));
+        }
     }
 
     closedir(d);
@@ -72,7 +75,7 @@
     LOG_VOL("bootstrap_controller(%s):", sysfs_path);
 #endif
     if (!(d = opendir(sysfs_path))) {
-        LOG_ERROR("Unable to open '%s' (%m)", sysfs_path);
+        LOG_ERROR("Unable to open '%s' (%s)", sysfs_path, strerror(errno));
         return -errno;
     }
 
@@ -92,7 +95,7 @@
         sprintf(tmp, "%s/%s", sysfs_path, de->d_name);
 
         if (mmc_bootstrap_card(tmp) < 0)
-            LOG_ERROR("Error bootstrapping card '%s' (%m)", tmp);
+            LOG_ERROR("Error bootstrapping card '%s' (%s)", tmp, strerror(errno));
     } // while
 
     closedir(d);
@@ -123,7 +126,7 @@
     }
     
     if (chdir(sysfs_path) < 0) {
-        LOGE("Unable to chdir to %s (%m)", sysfs_path);
+        LOGE("Unable to chdir to %s (%s)", sysfs_path, strerror(errno));
         return -errno;
     }
 
@@ -162,7 +165,7 @@
     uevent_params[3] = (char *) NULL;
 
     if (simulate_uevent("mmc", devpath, "add", uevent_params) < 0) {
-        LOGE("Error simulating uevent (%m)");
+        LOGE("Error simulating uevent (%s)", strerror(errno));
         return -errno;
     }
 
@@ -264,7 +267,7 @@
 
     sprintf(filename, "/sys%s/uevent", devpath);
     if (!(fp = fopen(filename, "r"))) {
-        LOGE("Unable to open '%s' (%m)", filename);
+        LOGE("Unable to open '%s' (%s)", filename, strerror(errno));
         return -errno;
     }
 
@@ -286,7 +289,7 @@
     uevent_params[4] = '\0';
     
     if (simulate_uevent("block", devpath, "add", uevent_params) < 0) {
-        LOGE("Error simulating uevent (%m)");
+        LOGE("Error simulating uevent (%s)", strerror(errno));
         return -errno;
     }
     return 0;