[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] Catch xen.xend.XendProtocol.XendError as well as xen.xend.XendError.XendError.
# HG changeset patch # User emellor@ewan # Node ID 4c4dbbda367ed9eb6004a40baa6cb27ba551c963 # Parent 5a3d5f9ef44e6733e5f5098b378867ef681cb4ee Catch xen.xend.XendProtocol.XendError as well as xen.xend.XendError.XendError. This horror needs cleaning up -- this is just a stopgap. Signed-off-by: Ewan Mellor <ewan@xxxxxxxxxxxxx> diff -r 5a3d5f9ef44e -r 4c4dbbda367e tools/python/xen/xm/main.py --- a/tools/python/xen/xm/main.py Tue Oct 4 10:42:06 2005 +++ b/tools/python/xen/xm/main.py Tue Oct 4 10:43:38 2005 @@ -32,6 +32,7 @@ warnings.filterwarnings('ignore', category=FutureWarning) import xen.xend.XendError +import xen.xend.XendProtocol from xen.xend import PrettyPrint from xen.xend import sxp @@ -710,6 +711,14 @@ print print "Please report to xen-devel@xxxxxxxxxxxxxxxxxxx" raise + except xen.xend.XendProtocol.XendError, ex: + if len(args) > 0: + handle_xend_error(argv[1], args[0], ex) + else: + print "Unexpected error:", sys.exc_info()[0] + print + print "Please report to xen-devel@xxxxxxxxxxxxxxxxxxx" + raise except SystemExit: sys.exit(1) except: _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |