Explorar o código

backup: fix handling labels in Qubes 4.0 backups

Labels can be referred as either id or name. Support both ways.

Fixes QubesOS/qubes-issues#3211
Marek Marczykowski-Górecki %!s(int64=6) %!d(string=hai) anos
pai
achega
7f728e2dad
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      qubesadmin/backup/core3.py

+ 1 - 0
qubesadmin/backup/core3.py

@@ -77,6 +77,7 @@ class Core3Qubes(qubesadmin.backup.BackupApp):
             ident = node.get('id')
             assert ident is not None
             self.labels[ident] = node.text
+            self.labels[node.text] = node.text
 
 
     def load_globals(self, globals_element):