[virt-manager PATCH 2/9] osdict: Return a _OsTree instead of OsinfoTree when guessing an OS

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Instead of returning an OsinfoTree, let's be consistent with what we
already do in guess_os_from_iso() and return our internal _OsTree
object.

This change doesn't affect any code as the only place using it doesn't
care about the returned tree object.

Signed-off-by: Fabiano Fidêncio <fidencio@xxxxxxxxxx>
---
 virtinst/osdict.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/virtinst/osdict.py b/virtinst/osdict.py
index 983f8e83..3b71ac31 100644
--- a/virtinst/osdict.py
+++ b/virtinst/osdict.py
@@ -263,7 +263,7 @@ class _OSDB(object):
         osobj, treeobj = self._os_loader.get_db().guess_os_from_tree(tree)
         if not osobj:
             return None  # pragma: no cover
-        return osobj.get_short_id(), treeobj
+        return osobj.get_short_id(), _OsTree(treeobj)
 
     def list_os(self):
         """
-- 
2.21.0

_______________________________________________
virt-tools-list mailing list
virt-tools-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/virt-tools-list




[Index of Archives]     [Linux Virtualization]     [KVM Development]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]     [Video 4 Linux]

  Powered by Linux