Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(16)

Unified Diff: tools/usb_gadget/package.py

Issue 799073005: Write the packaged USB gadget app in binary mode. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/usb_gadget/package.py
diff --git a/tools/usb_gadget/package.py b/tools/usb_gadget/package.py
index 069bb1477d7738e8d6a3f3152c430aed5c37c089..1c5003325662acc715c1dc9463675c2cfde0e554 100755
--- a/tools/usb_gadget/package.py
+++ b/tools/usb_gadget/package.py
@@ -82,10 +82,10 @@ def main():
content, md5 = MakeZip(directory=args.dir, files=args.files)
if args.zip_file:
- with open(args.zip_file, 'w') as zip_file:
+ with open(args.zip_file, 'wb') as zip_file:
zip_file.write(content)
if args.hash_file:
- with open(args.hash_file, 'w') as hash_file:
+ with open(args.hash_file, 'wb') as hash_file:
hash_file.write(md5)
if args.upload:
UploadZip(content, md5, args.upload)
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698