From 69b4102c996f1793dbc7280924ae023281f94d30 Mon Sep 17 00:00:00 2001 From: Pedro de Medeiros Date: Wed, 2 Jun 2021 22:31:12 -0300 Subject: map.py: remove generated files on error --- tools/map.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'tools') diff --git a/tools/map.py b/tools/map.py index c2e2212..53c98b7 100755 --- a/tools/map.py +++ b/tools/map.py @@ -318,6 +318,7 @@ def main(): if args.bin: for i, block in enumerate(out): filename = path.join(args.dir, "%s%02d.bin" % (args.id, i)) + remove_list.append(filename) with open(filename, "wb") as fd: if i in empty: fd.write(struct.pack("