From patchwork Sun May 8 18:58:04 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sasha Levin X-Patchwork-Id: 766402 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p48Iwf7s021099 for ; Sun, 8 May 2011 18:58:42 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932225Ab1EHS6j (ORCPT ); Sun, 8 May 2011 14:58:39 -0400 Received: from mail-wy0-f174.google.com ([74.125.82.174]:56516 "EHLO mail-wy0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932215Ab1EHS6i (ORCPT ); Sun, 8 May 2011 14:58:38 -0400 Received: by wya21 with SMTP id 21so3429990wya.19 for ; Sun, 08 May 2011 11:58:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:from:to:cc:subject:date:message-id:x-mailer; bh=yzjmpWA7Xd1osytTW1GSg1w+3KOA3TOjrNQlToXsNX0=; b=kD8vVwz/AgEmoHTzYXFLHqgi23BW9hjgfd56T9XiUuvbiqcm3vf64Fl1YTSRLZkQEl hRtbfeyIMLx0v1uWwyUllzZwqJn4jHp/lzgzNFjNVcBO89PiyciZRTGUDIick1B06p/P yPvsGZ9tcW6f5frOEDo+VWkKgrMlfVZf2B0kM= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer; b=TpUSONFn1bTeWnq1nJQu71DDX6GgSR3e/IHuM3HXhA7v1nmKKwh4Od4xPyM7+uUXPK drU9hX4L9ow+WAn3YyUEeKmC499Kj8hxIsZC98JeOhF7Ly0VeLsGQbtzD+J0aetvPPRP YtUbJwV+BUzEtAeAJ7OgY53zGUcuF9lU/EX0o= Received: by 10.227.2.81 with SMTP id 17mr6413286wbi.15.1304881117102; Sun, 08 May 2011 11:58:37 -0700 (PDT) Received: from localhost.localdomain (bzq-79-179-206-225.red.bezeqint.net [79.179.206.225]) by mx.google.com with ESMTPS id z9sm3297954wbx.34.2011.05.08.11.58.35 (version=TLSv1/SSLv3 cipher=OTHER); Sun, 08 May 2011 11:58:36 -0700 (PDT) From: Sasha Levin To: penberg@kernel.org Cc: mingo@elte.hu, asias.hejun@gmail.com, gorcunov@gmail.com, prasadjoshi124@gmail.com, kvm@vger.kernel.org, Sasha Levin Subject: [PATCH] kvm tools: Add missing space after kernel params Date: Sun, 8 May 2011 21:58:04 +0300 Message-Id: <1304881084-4316-1-git-send-email-levinsasha928@gmail.com> X-Mailer: git-send-email 1.7.5.rc3 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Sun, 08 May 2011 18:58:42 +0000 (UTC) Add missing space so that user-provided kernel params will be properly concatenated to default params. Instead of just adding a space at the end, add it with a separate strcat(), since it's not the first (and wouldn't have been the last) time a space wasn't added. Reported-by: Rodrigo Campos Signed-off-by: Sasha Levin --- tools/kvm/kvm-run.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/tools/kvm/kvm-run.c b/tools/kvm/kvm-run.c index 58e2977..d8ef4c9 100644 --- a/tools/kvm/kvm-run.c +++ b/tools/kvm/kvm-run.c @@ -424,6 +424,7 @@ int kvm_cmd_run(int argc, const char **argv, const char *prefix) memset(real_cmdline, 0, sizeof(real_cmdline)); strcpy(real_cmdline, "notsc noapic noacpi pci=conf1 console=ttyS0 earlyprintk=serial"); + strcat(real_cmdline, " "); if (kernel_cmdline) strlcat(real_cmdline, kernel_cmdline, sizeof(real_cmdline));