summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJP Abgrall <jpa@google.com>2014-02-14 17:31:40 -0800
committerSteve Kondik <shade@chemlab.org>2014-04-07 15:31:44 -0700
commitce52b565b92240bfdd24f27f5e914586eca0fe0c (patch)
tree2b50c8b1425ec3510db3ab17d2038757b523595d
parent513d66f4984c4e38e9a3179956d0b2f59db3e710 (diff)
downloadandroid_system_extras-stable/cm-11.0-XNF8Y.tar.gz
android_system_extras-stable/cm-11.0-XNF8Y.tar.bz2
android_system_extras-stable/cm-11.0-XNF8Y.zip
Bug: 13029951 Change-Id: Ibe50a503c2d3988813b362790b7fba83383fb51e
-rw-r--r--ext4_utils/make_ext4fs_main.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ext4_utils/make_ext4fs_main.c b/ext4_utils/make_ext4fs_main.c
index b6c740d2..754e51f0 100644
--- a/ext4_utils/make_ext4fs_main.c
+++ b/ext4_utils/make_ext4fs_main.c
@@ -203,6 +203,7 @@ int main(int argc, char **argv)
exitcode = make_ext4fs_internal(fd, directory, mountpoint, fs_config_func, gzip,
sparse, crc, wipe, sehnd, verbose);
close(fd);
-
+ if (exitcode && strcmp(filename, "-"))
+ unlink(filename);
return exitcode;
}