On 04/22/2013 10:58 AM, Martin Kletzander wrote: > In case there was '.treeinfo' file available, virt-install was > forcibly getting image information out of the file. For some > distributions (especially older releases, e.g. RHEL 4), there might be > '.treeinfo' file available, but with incomplete information. Allow > fallback to default values even when '.treeinfo' file is found. > > Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=954262 > > Signed-off-by: Martin Kletzander <mkletzan@xxxxxxxxxx> > --- > virtinst/OSDistro.py | 12 ++++++++---- > 1 file changed, 8 insertions(+), 4 deletions(-) > > diff --git a/virtinst/OSDistro.py b/virtinst/OSDistro.py > index f88874b..5ecfdf6 100644 > --- a/virtinst/OSDistro.py > +++ b/virtinst/OSDistro.py > @@ -1,7 +1,7 @@ > # > # Represents OS distribution specific install data > # > -# Copyright 2006-2007 Red Hat, Inc. > +# Copyright 2006-2007, 2013 Red Hat, Inc. > # Daniel P. Berrange <berrange@xxxxxxxxxx> > # > # This program is free software; you can redistribute it and/or modify > @@ -268,9 +268,13 @@ class Distro: > kernelpath = None > initrdpath = None > if self._hasTreeinfo(fetcher, progresscb): > - kernelpath = self._getTreeinfoMedia("kernel") > - initrdpath = self._getTreeinfoMedia("initrd") > - else: > + try: > + kernelpath = self._getTreeinfoMedia("kernel") > + initrdpath = self._getTreeinfoMedia("initrd") > + except ConfigParser.NoSectionError: > + pass > + > + if not kernelpath or not initrdpath: > # fall back to old code > if self.type is None or self.type == "hvm": > paths = self._hvm_kernel_paths > ACK, please apply. There's also a 0.6-maint branch of virtinst.git if you want to push it there as well. Thanks, Cole _______________________________________________ virt-tools-list mailing list virt-tools-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/virt-tools-list