summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbohu <bohu@google.com>2019-05-21 22:09:49 -0700
committerLuca Stefani <luca.stefani.ge1@gmail.com>2019-09-06 13:40:11 +0200
commitcbe0ed35a63e76b0e9fd87516036cd888fe9f715 (patch)
treedf5b02ccfa10bde5efadea2a13f6a55ab58280cd
parent6a722d785caa46ddd805f50ed0734fda5a992e99 (diff)
downloadandroid_device_generic_goldfish-cbe0ed35a63e76b0e9fd87516036cd888fe9f715.tar.gz
android_device_generic_goldfish-cbe0ed35a63e76b0e9fd87516036cd888fe9f715.tar.bz2
android_device_generic_goldfish-cbe0ed35a63e76b0e9fd87516036cd888fe9f715.zip
goldfish: clean up stale qcow2 file
when create a new combined image Handy in the build environment to avoid stale qcow2 file that could fail the boot Change-Id: I962eb3041da25ac0129246536a9bac2d7dd96af2 Merged-In: I962eb3041da25ac0129246536a9bac2d7dd96af2
-rwxr-xr-xtools/mk_combined_img.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/tools/mk_combined_img.py b/tools/mk_combined_img.py
index 1b7bbff..1f195ac 100755
--- a/tools/mk_combined_img.py
+++ b/tools/mk_combined_img.py
@@ -113,6 +113,10 @@ def main():
output_filename = os.path.expandvars(args.output)
+ # remove the output_filename.qcow2
+ print "removing " + output_filename + ".qcow2"
+ shell_command(['rm', '-rf', output_filename + ".qcow2"])
+
# check input file
config_filename = args.input
if not os.path.exists(config_filename):