WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] [PYGRUB] Invoke pygrub with TERM=vt100

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] [PYGRUB] Invoke pygrub with TERM=vt100
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Thu, 01 Feb 2007 13:35:13 -0800
Delivery-date: Thu, 01 Feb 2007 13:35:45 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Tim Deegan <Tim.Deegan@xxxxxxxxxxxxx>
# Date 1170342217 0
# Node ID 1c7efb60176c3542fe06eeec84c230aab5e38bc2
# Parent  6e81102d29be5c688c0e77c9ef3303c677264e91
[PYGRUB] Invoke pygrub with TERM=vt100
Signed-off-by: Tim Deegan <Tim.Deegan@xxxxxxxxxxxxx>
---
 tools/pygrub/src/pygrub                 |    5 ++++-
 tools/python/xen/xend/XendBootloader.py |    4 +++-
 2 files changed, 7 insertions(+), 2 deletions(-)

diff -r 6e81102d29be -r 1c7efb60176c tools/pygrub/src/pygrub
--- a/tools/pygrub/src/pygrub   Thu Feb 01 13:15:03 2007 +0000
+++ b/tools/pygrub/src/pygrub   Thu Feb 01 15:03:37 2007 +0000
@@ -197,7 +197,10 @@ class Grub:
             self.screen = curses.initscr()
             self.screen.timeout(1000)
             if hasattr(curses, 'use_default_colors'):
-                curses.use_default_colors()
+                try:
+                    curses.use_default_colors()
+                except:
+                    pass # Not important if we can't use colour
             enable_cursor(False)
             self.entry_win = curses.newwin(10, 74, 2, 1)
             self.text_win = curses.newwin(10, 70, 12, 5)
diff -r 6e81102d29be -r 1c7efb60176c tools/python/xen/xend/XendBootloader.py
--- a/tools/python/xen/xend/XendBootloader.py   Thu Feb 01 13:15:03 2007 +0000
+++ b/tools/python/xen/xend/XendBootloader.py   Thu Feb 01 15:03:37 2007 +0000
@@ -97,7 +97,9 @@ def bootloader(blexec, disk, dom, quiet 
 
         try:
             log.debug("Launching bootloader as %s." % str(args))
-            os.execvp(args[0], args)
+            env = os.environ.copy()
+            env['TERM'] = 'vt100'
+            os.execvpe(args[0], args, env)
         except OSError, e:
             print e
             pass

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] [PYGRUB] Invoke pygrub with TERM=vt100, Xen patchbot-unstable <=