summaryrefslogtreecommitdiffstats
path: root/updater/blockimg.c
diff options
context:
space:
mode:
Diffstat (limited to 'updater/blockimg.c')
-rw-r--r--updater/blockimg.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/updater/blockimg.c b/updater/blockimg.c
index 54f76ffd3..5d0f1560c 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;
}
}
}