# HG changeset patch
# User Keir Fraser <keir@xen.org>
# Date 1288345463 -3600
# Node ID 179150c0b36614a6a596ca5e872fea80d852a819
# Parent  18a752a248116454e2259a2d88c801835d19532f
pygrub: support grub2 "(hdX,msdosY)" partition syntax

This appeared in Debian Squeeze at some point.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
committer: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
xen-unstable changeset:   22238:6eaab8297681
xen-unstable date:        Wed Oct 13 11:45:26 2010 +0100

diff -r 18a752a24811 -r 179150c0b366 tools/pygrub/src/GrubConf.py
--- a/tools/pygrub/src/GrubConf.py	Sun Oct 24 13:30:17 2010 +0100
+++ b/tools/pygrub/src/GrubConf.py	Fri Oct 29 10:44:23 2010 +0100
@@ -77,6 +77,8 @@
             self._part = val
             return
         val = val.replace("(", "").replace(")", "")
+        if val[:5] == "msdos":
+            val = val[5:]
         self._part = int(val)
     part = property(get_part, set_part)
 
