From 6f04c8d65b5523184f4efdb15471256b761e8262 Mon Sep 17 00:00:00 2001 From: Galland Date: Tue, 21 Aug 2018 03:08:17 +0200 Subject: [PATCH] Fix error on non ASCII PCI IDs upon qvm-device list solves https://github.com/QubesOS/qubes-issues/issues/4229 --- qubes/ext/pci.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qubes/ext/pci.py b/qubes/ext/pci.py index bd5f34cc..3c4a2f93 100644 --- a/qubes/ext/pci.py +++ b/qubes/ext/pci.py @@ -42,7 +42,7 @@ def load_pci_classes(): # subclass subclass_name <-- single tab # prog-if prog-if_name <-- two tabs result = {} - with open('/usr/share/hwdata/pci.ids') as pciids: + with open('/usr/share/hwdata/pci.ids', encoding='utf-8', errors='ignore') as pciids: class_id = None subclass_id = None for line in pciids.readlines():