1
0
mirror of https://github.com/mbirth/tcl_ota_check.git synced 2024-09-19 22:33:25 +01:00

add OS version to header name

This commit is contained in:
thurask 2017-09-07 12:54:17 -04:00
parent 1ba638df00
commit 237280cbea
No known key found for this signature in database
GPG Key ID: A6CCCDEA29795048
2 changed files with 3 additions and 3 deletions

2
.gitignore vendored
View File

@ -1,3 +1,3 @@
/__pycache__/
/.nvimlog
/header.bin
/header*.bin

View File

@ -39,8 +39,8 @@ for s in slaves:
if fc.mode == fc.MODE_FULL:
header = fc.do_encrypt_header(random.choice(encslaves), fileurl)
if len(header) == 4194320:
print("Header length check passed. Writing to header.bin.")
with open("header.bin", "wb") as f:
print("Header length check passed. Writing to header_{}.bin.".format(tv))
with open("header_{}.bin".format(tv), "wb") as f:
f.write(header)
else:
print("Header length invalid ({}).".format(len(header)))