summaryrefslogtreecommitdiffstats
path: root/updater/blockimg.c
diff options
context:
space:
mode:
authorSami Tolvanen <samitolvanen@google.com>2015-04-27 12:24:29 +0200
committerSami Tolvanen <samitolvanen@google.com>2015-05-28 10:09:02 +0200
commitcc2428c8181d18c9a88db908fa4eabd2db5601ad (patch)
treea37550c760bf26300ed6e6277510b96da8c753c8 /updater/blockimg.c
parentMerge "Clean up the sleep()'s after poking init services" (diff)
downloadandroid_bootable_recovery-cc2428c8181d18c9a88db908fa4eabd2db5601ad.tar
android_bootable_recovery-cc2428c8181d18c9a88db908fa4eabd2db5601ad.tar.gz
android_bootable_recovery-cc2428c8181d18c9a88db908fa4eabd2db5601ad.tar.bz2
android_bootable_recovery-cc2428c8181d18c9a88db908fa4eabd2db5601ad.tar.lz
android_bootable_recovery-cc2428c8181d18c9a88db908fa4eabd2db5601ad.tar.xz
android_bootable_recovery-cc2428c8181d18c9a88db908fa4eabd2db5601ad.tar.zst
android_bootable_recovery-cc2428c8181d18c9a88db908fa4eabd2db5601ad.zip
Diffstat (limited to '')
-rw-r--r--updater/blockimg.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/updater/blockimg.c b/updater/blockimg.c
index ce6360099..42060f547 100644
--- a/updater/blockimg.c
+++ b/updater/blockimg.c
@@ -1485,7 +1485,6 @@ static int PerformCommandErase(CommandParameters* params) {
if (!S_ISBLK(st.st_mode)) {
fprintf(stderr, "not a block device; skipping erase\n");
- rc = 0;
goto pceout;
}
@@ -1509,7 +1508,7 @@ static int PerformCommandErase(CommandParameters* params) {
if (ioctl(params->fd, BLKDISCARD, &blocks) == -1) {
fprintf(stderr, "BLKDISCARD ioctl failed: %s\n", strerror(errno));
- // Continue anyway, nothing we can do
+ goto pceout;
}
}
}