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] libxl: fix xenstore connection when run i

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] libxl: fix xenstore connection when run in domU
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 03 Sep 2010 09:50:22 -0700
Delivery-date: Fri, 03 Sep 2010 09:51:14 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
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/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/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 Daniel De Graaf <dgdegra@xxxxxxxxxxxxx>
# Date 1283173087 -3600
# Node ID cd2ca6c3f2e42261a562107c4fd1a4bb0b922a0b
# Parent  c5aed2e049bce2724b035dd6aa09c4c4e609c27c
libxl: fix xenstore connection when run in domU

When used in a domain other than the one running xenstore,
libxl_ctx_init will fail to connect even when xenstore is actually
available. Add a call to xs_domain_open to handle this case.

Signed-off-by: Daniel De Graaf <dgdegra@xxxxxxxxxxxxx>
Signed-off-by: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
committer: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
---
 tools/libxl/libxl.c |    2 ++
 1 files changed, 2 insertions(+)

diff -r c5aed2e049bc -r cd2ca6c3f2e4 tools/libxl/libxl.c
--- a/tools/libxl/libxl.c       Mon Aug 30 08:39:52 2010 +0100
+++ b/tools/libxl/libxl.c       Mon Aug 30 13:58:07 2010 +0100
@@ -54,6 +54,8 @@ int libxl_ctx_init(libxl_ctx *ctx, int v
     }
 
     ctx->xsh = xs_daemon_open();
+    if (!ctx->xsh)
+        ctx->xsh = xs_domain_open();
     if (!ctx->xsh) {
         XL_LOG_ERRNOVAL(ctx, XL_LOG_ERROR, errno, 
                         "cannot connect to xenstore");

_______________________________________________
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] libxl: fix xenstore connection when run in domU, Xen patchbot-unstable <=