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

[Xen-changelog] [xen-unstable] xl: Remove transaction handle in "xl rename"



# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1273480037 -3600
# Node ID c7e9f1b99b2293172f8d5536aff47c9e7d852ab7
# Parent  6eda6d4a9d2c0f669a1ee75579b000a795a9782a
xl: Remove transaction handle in "xl rename"

Thanks Stefano for pointing out that transaction handle in libxl
clients is not needed.

Signed-off-by: Yang Hongyang <yanghy@xxxxxxxxxxxxxx>
---
 tools/libxl/xl_cmdimpl.c |    9 +--------
 1 files changed, 1 insertion(+), 8 deletions(-)

diff -r 6eda6d4a9d2c -r c7e9f1b99b22 tools/libxl/xl_cmdimpl.c
--- a/tools/libxl/xl_cmdimpl.c  Mon May 10 09:26:29 2010 +0100
+++ b/tools/libxl/xl_cmdimpl.c  Mon May 10 09:27:17 2010 +0100
@@ -3078,7 +3078,6 @@ int main_rename(int argc, char **argv)
     int opt;
     char *dom;
     char *new_name;
-    xs_transaction_t t;
 
     while ((opt = getopt(argc, argv, "h")) != -1) {
         switch (opt) {
@@ -3101,16 +3100,10 @@ int main_rename(int argc, char **argv)
     find_domain(dom);
     new_name = argv[optind];
 
-retry_transaction:
-    t = xs_transaction_start(ctx.xsh);
-    if (libxl_domain_rename(&ctx, domid, common_domname, new_name, t)) {
+    if (libxl_domain_rename(&ctx, domid, common_domname, new_name, 0)) {
         fprintf(stderr, "Can't rename domain '%s'.\n", dom);
         exit(1);
     }
 
-    if (!xs_transaction_end(ctx.xsh, t, 0))
-        if (errno == EAGAIN)
-            goto retry_transaction;
-
     exit(0);
 }

_______________________________________________
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®.