[getn-hb-version.py] Open old output in UTF-8 mode as well

Fixes https://github.com/harfbuzz/harfbuzz/issues/3227
This commit is contained in:
Behdad Esfahbod 2021-09-23 08:39:29 -06:00
parent 9247d24d7f
commit 6f19094398
1 changed files with 1 additions and 1 deletions

View File

@ -15,7 +15,7 @@ INPUT = sys.argv[3]
CURRENT_SOURCE_DIR = os.path.dirname(INPUT)
try:
with open (OUTPUT, "r") as old_output:
with open (OUTPUT, "r", encoding='utf-8') as old_output:
for line in old_output:
old_version = re.match (r"#define HB_VERSION_STRING \"(\d.\d.\d)\"", line)
if old_version and old_version[1] == version: