build: read node files as binary files (#28735)

Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
This commit is contained in:
trop[bot]
2021-04-19 20:01:27 -04:00
committed by GitHub
parent 287c9eb8c0
commit 5bbc64b416

View File

@@ -88,7 +88,7 @@ def create_checksum(algorithm, directory, filename, files):
lines = []
for path in files:
h = hashlib.new(algorithm)
with open(path, 'r') as f:
with open(path, 'rb') as f:
h.update(f.read())
lines.append(h.hexdigest() + ' ' + os.path.relpath(path, directory))