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] [XEND] Fix fallback and error path for do

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] [XEND] Fix fallback and error path for domain destruction by domid,
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Tue, 08 Aug 2006 14:50:20 +0000
Delivery-date: Tue, 08 Aug 2006 07:53:37 -0700
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 kaf24@xxxxxxxxxxxxxxxxxxxx
# Node ID 51c2274281664b79db70d3a5b63741e4a482803c
# Parent  82230c3273e3624e3ef12e7c1174277a1c9afb96
[XEND] Fix fallback and error path for domain destruction by domid,
or of non-existent domain.

I saw the following error message. (A domain of domain name XXX does 
not exist.)

# xm list
Name                              ID Mem(MiB) VCPUs State  Time(s)
Domain-0                           0     1019     2 r-----    29.8
# xm destroy XXX
Error: an integer is required

This patch fixes it to print the following error message.

# xm list
Name                              ID Mem(MiB) VCPUs State  Time(s)
Domain-0                           0     1019     2 r-----    35.8
# xm destroy XXX
Error: the domain 'XXX' does not exist.

Signed-off-by: Masaki Kanno <kanno.masaki@xxxxxxxxxxxxxx>
---
 tools/python/xen/xend/XendDomain.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff -r 82230c3273e3 -r 51c227428166 tools/python/xen/xend/XendDomain.py
--- a/tools/python/xen/xend/XendDomain.py       Tue Aug 08 09:59:47 2006 +0100
+++ b/tools/python/xen/xend/XendDomain.py       Tue Aug 08 10:03:30 2006 +0100
@@ -402,9 +402,9 @@ class XendDomain:
             val = dominfo.destroy()
         else:
             try:
-                val = xc.domain_destroy(domid)
+                val = xc.domain_destroy(int(domid))
             except Exception, ex:
-                raise XendError(str(ex))
+                raise XendInvalidDomain(str(domid))
         return val       
 
     def domain_migrate(self, domid, dst, live=False, resource=0, port=0):

_______________________________________________
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] [XEND] Fix fallback and error path for domain destruction by domid,, Xen patchbot-unstable <=