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-3.1-testing] Fix string length check for vsnprintf(

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-3.1-testing] Fix string length check for vsnprintf() in debugtrace_printk().
From: "Xen patchbot-3.1-testing" <patchbot-3.1-testing@xxxxxxxxxxxxxxxxxxx>
Date: Mon, 10 Dec 2007 03:10:40 -0800
Delivery-date: Mon, 10 Dec 2007 03:29:04 -0800
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 Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1196960532 0
# Node ID 8cf7f24330ff3248557c3766166336987c530bb9
# Parent  fc71e417e0ebe380dbd74099f882891430dc50fa
Fix string length check for vsnprintf() in debugtrace_printk().
Signed-off-by: Christoph Egger <Christoph.Egger@xxxxxxx>
xen-unstable changeset:   16484:bb31c9325d5f86629de342a6515c6f28b92cf782
xen-unstable date:        Wed Nov 28 12:50:24 2007 +0000
---
 xen/drivers/char/console.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

diff -r fc71e417e0eb -r 8cf7f24330ff xen/drivers/char/console.c
--- a/xen/drivers/char/console.c        Thu Dec 06 17:01:46 2007 +0000
+++ b/xen/drivers/char/console.c        Thu Dec 06 17:02:12 2007 +0000
@@ -787,7 +787,7 @@ void debugtrace_printk(const char *fmt, 
     snprintf(buf, sizeof(buf), "%u ", ++count);
 
     va_start(args, fmt);
-    (void)vsnprintf(buf + strlen(buf), sizeof(buf), fmt, args);
+    (void)vsnprintf(buf + strlen(buf), sizeof(buf) - strlen(buf), fmt, args);
     va_end(args);
 
     if ( debugtrace_send_to_console )

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-3.1-testing] Fix string length check for vsnprintf() in debugtrace_printk()., Xen patchbot-3.1-testing <=