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 up some incorrect printf forma

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] libxl: Fix up some incorrect printf formats
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Sat, 29 May 2010 00:31:09 -0700
Delivery-date: Sat, 29 May 2010 00:35:39 -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 Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1275035503 -3600
# Node ID ca77b846772fb19bcf20d11d2f67fc70f444febd
# Parent  65a7ac5e0a0abbfe8347a83913215964e50d9587
libxl: Fix up some incorrect printf formats

We need to use PRIu32 for domids, and also to pass arguments in the
right order.

Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
---
 tools/libxl/libxl.c        |    4 ++--
 tools/libxl/libxl_dom.c    |    2 +-
 tools/libxl/libxl_xshelp.c |    3 ++-
 3 files changed, 5 insertions(+), 4 deletions(-)

diff -r 65a7ac5e0a0a -r ca77b846772f tools/libxl/libxl.c
--- a/tools/libxl/libxl.c       Fri May 28 09:31:09 2010 +0100
+++ b/tools/libxl/libxl.c       Fri May 28 09:31:43 2010 +0100
@@ -230,7 +230,7 @@ int libxl_domain_rename(struct libxl_ctx
                   new_name, strlen(new_name))) {
         XL_LOG(ctx, XL_LOG_ERROR, "failed to write new name `%s'"
                " for domain %"PRIu32" previously named `%s'",
-               domid, new_name, old_name);
+               new_name, domid, old_name);
         goto x_fail;
     }
 
@@ -240,7 +240,7 @@ int libxl_domain_rename(struct libxl_ctx
             if (errno != EAGAIN) {
                 XL_LOG(ctx, XL_LOG_ERROR, "failed to commit new name `%s'"
                        " for domain %"PRIu32" previously named `%s'",
-                       domid, new_name, old_name);
+                       new_name, domid, old_name);
                 goto x_fail;
             }
             XL_LOG(ctx, XL_LOG_DEBUG, "need to retry rename transaction"
diff -r 65a7ac5e0a0a -r ca77b846772f tools/libxl/libxl_dom.c
--- a/tools/libxl/libxl_dom.c   Fri May 28 09:31:09 2010 +0100
+++ b/tools/libxl/libxl_dom.c   Fri May 28 09:31:43 2010 +0100
@@ -386,7 +386,7 @@ static const char *userdata_path(struct 
     rc = libxl_domain_info(ctx, &info, domid);
     if (rc) {
         XL_LOG_ERRNO(ctx, XL_LOG_ERROR, "unable to find domain info"
-                     " for domain %l"PRIu32, domid);
+                     " for domain %"PRIu32, domid);
         return 0;
     }
     uuid_string = string_of_uuid(ctx, info.uuid);
diff -r 65a7ac5e0a0a -r ca77b846772f tools/libxl/libxl_xshelp.c
--- a/tools/libxl/libxl_xshelp.c        Fri May 28 09:31:09 2010 +0100
+++ b/tools/libxl/libxl_xshelp.c        Fri May 28 09:31:43 2010 +0100
@@ -19,6 +19,7 @@
 #include <stddef.h>
 #include <stdio.h>
 #include <stdarg.h>
+#include <inttypes.h>
 
 #include "libxl.h"
 #include "libxl_internal.h"
@@ -119,7 +120,7 @@ char *libxl_xs_get_dompath(struct libxl_
 {
     char *s = xs_get_domain_path(ctx->xsh, domid);
     if (!s) {
-        XL_LOG_ERRNO(ctx, XL_LOG_ERROR, "failed to get dompath for %lu",
+        XL_LOG_ERRNO(ctx, XL_LOG_ERROR, "failed to get dompath for %" PRIu32,
                      domid);
         return NULL;
     }

_______________________________________________
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 up some incorrect printf formats, Xen patchbot-unstable <=