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] Handle the case where there are no spaces or parameters

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] Handle the case where there are no spaces or parameters
From: Xen patchbot -unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 05 Oct 2005 13:16:11 +0000
Delivery-date: Wed, 05 Oct 2005 13:13:44 +0000
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/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 kaf24@xxxxxxxxxxxxxxxxxxxx
# Node ID e643fccb851bb5ef271057e02455661f4beff1bc
# Parent  8be7026371836fbeca738826391649cd00a2b947
Handle the case where there are no spaces or parameters
after the image name on the command line.

Signed-off-by: Mike Day <mdday@xxxxxxxxxx>

diff -r 8be702637183 -r e643fccb851b xen/arch/x86/setup.c
--- a/xen/arch/x86/setup.c      Wed Oct  5 13:06:23 2005
+++ b/xen/arch/x86/setup.c      Wed Oct  5 13:10:49 2005
@@ -475,13 +475,14 @@
     {
         static char dom0_cmdline[MAX_GUEST_CMDLINE];
 
-        /* Skip past the image name. */
+        /* Skip past the image name and copy to a local buffer. */
         while ( *cmdline == ' ' ) cmdline++;
         if ( (cmdline = strchr(cmdline, ' ')) != NULL )
+        {
             while ( *cmdline == ' ' ) cmdline++;
-
-        /* Copy the command line to a local buffer. */
-        strcpy(dom0_cmdline, cmdline);
+            strcpy(dom0_cmdline, cmdline);
+        }
+
         cmdline = dom0_cmdline;
 
         /* Append any extra parameters. */

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] Handle the case where there are no spaces or parameters, Xen patchbot -unstable <=