Explorar el Código

qubes/vm/qubesvm: fix qid setter to accept str

Mainly for loading from XML.
Wojtek Porczyk hace 9 años
padre
commit
7886695c63
Se han modificado 1 ficheros con 1 adiciones y 0 borrados
  1. 1 0
      qubes/vm/qubesvm.py

+ 1 - 0
qubes/vm/qubesvm.py

@@ -57,6 +57,7 @@ except ImportError:
 
 def _setter_qid(self, prop, value):
     # pylint: disable=unused-argument
+    value = int(value)
     if not 0 <= value <= qubes.config.max_qid:
         raise ValueError(
             '{} value must be between 0 and qubes.config.max_qid'.format(