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

[Xen-changelog] [xen-unstable] pygrub: fix attribute error when not found parser



# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1260966057 0
# Node ID f9998fedea78fb8a263a5eae8c747c76ed2fee99
# Parent  d7403d17d03a98eb744193b817460350a91c45ba
pygrub: fix attribute error when not found parser

Signed-off-by: Wei Kong <weikong.cn@xxxxxxxxx>
---
 tools/pygrub/src/pygrub |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

diff -r d7403d17d03a -r f9998fedea78 tools/pygrub/src/pygrub
--- a/tools/pygrub/src/pygrub   Wed Dec 16 12:20:08 2009 +0000
+++ b/tools/pygrub/src/pygrub   Wed Dec 16 12:20:57 2009 +0000
@@ -397,7 +397,7 @@ class Grub:
                 self.cf = parser()
                 self.cf.filename = f
                 break
-        if self.cf.filename is None:
+        if self.__dict__.get('cf', None) is None:
             raise RuntimeError, "couldn't find bootloader config file in the 
image provided."
         f = fs.open_file(self.cf.filename)
         buf = f.read()

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.