From f88441c584e730243a8b5cfca31f297d90f876dd Mon Sep 17 00:00:00 2001 From: rdb Date: Tue, 17 Nov 2020 12:01:05 +0100 Subject: [PATCH] dist: Fix error building Windows executable in Python 3.9 --- direct/src/dist/pefile.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/direct/src/dist/pefile.py b/direct/src/dist/pefile.py index 548c09e1b7..df7aac8432 100755 --- a/direct/src/dist/pefile.py +++ b/direct/src/dist/pefile.py @@ -246,7 +246,11 @@ class VersionInfoResource(object): length, value_length = unpack('= (3, 2): + dwords.frombytes(bytes(data[40:offset])) + else: + dwords.fromstring(bytes(data[40:offset])) + if len(dwords) > 0: self.signature = dwords[0] if len(dwords) > 1: