summaryrefslogtreecommitdiff
path: root/hwdb/parse_hwdb.py
diff options
context:
space:
mode:
Diffstat (limited to 'hwdb/parse_hwdb.py')
-rwxr-xr-xhwdb/parse_hwdb.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/hwdb/parse_hwdb.py b/hwdb/parse_hwdb.py
index 556b859191..5d4c5ea64d 100755
--- a/hwdb/parse_hwdb.py
+++ b/hwdb/parse_hwdb.py
@@ -133,8 +133,7 @@ def convert_properties(group):
def parse(fname):
grammar = hwdb_grammar()
try:
- with open(fname, 'r', encoding='UTF-8') as f:
- parsed = grammar.parseFile(f)
+ parsed = grammar.parseFile(fname)
except ParseBaseException as e:
error('Cannot parse {}: {}', fname, e)
return []