From patchwork Thu Jan 29 12:52:44 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Gonglei (Arei)" X-Patchwork-Id: 434549 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 06AF01402D1 for ; Thu, 29 Jan 2015 23:56:04 +1100 (AEDT) Received: from localhost ([::1]:59278 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YGodd-00024R-W7 for incoming@patchwork.ozlabs.org; Thu, 29 Jan 2015 07:56:02 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60008) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YGock-0000z5-EN for qemu-devel@nongnu.org; Thu, 29 Jan 2015 07:55:10 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YGocg-0001Pn-Ep for qemu-devel@nongnu.org; Thu, 29 Jan 2015 07:55:06 -0500 Received: from szxga01-in.huawei.com ([119.145.14.64]:16627) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YGocf-0001PC-RB for qemu-devel@nongnu.org; Thu, 29 Jan 2015 07:55:02 -0500 Received: from 172.24.2.119 (EHLO szxeml432-hub.china.huawei.com) ([172.24.2.119]) by szxrg01-dlp.huawei.com (MOS 4.3.7-GA FastPath queued) with ESMTP id CIS84047; Thu, 29 Jan 2015 20:54:59 +0800 (CST) Received: from localhost (10.177.19.102) by szxeml432-hub.china.huawei.com (10.82.67.209) with Microsoft SMTP Server id 14.3.158.1; Thu, 29 Jan 2015 20:53:10 +0800 From: To: Date: Thu, 29 Jan 2015 20:52:44 +0800 Message-ID: <1422535966-9948-2-git-send-email-arei.gonglei@huawei.com> X-Mailer: git-send-email 1.7.3.1.msysgit.0 In-Reply-To: <1422535966-9948-1-git-send-email-arei.gonglei@huawei.com> References: <1422535966-9948-1-git-send-email-arei.gonglei@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.177.19.102] X-CFilter-Loop: Reflected X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 119.145.14.64 Cc: Gonglei , kraxel@redhat.com, peter.huangpeng@huawei.com Subject: [Qemu-devel] [PATCH 1/3] vnc: fix qemu crash when not configure vnc option X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org From: Gonglei Reproducer: $ x86_64-softmmu/qemu-system-x86_64 qemu-system-x86_64: Invalid parameter 'to' Segmentation fault (core dumped) Signed-off-by: Gonglei --- ui/vnc.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/ui/vnc.c b/ui/vnc.c index a742c90..08b8b24 100644 --- a/ui/vnc.c +++ b/ui/vnc.c @@ -3276,6 +3276,15 @@ static QemuOptsList qemu_vnc_opts = { .name = "connections", .type = QEMU_OPT_NUMBER, },{ + .name = "to", + .type = QEMU_OPT_NUMBER, + },{ + .name = "ipv4", + .type = QEMU_OPT_BOOL, + },{ + .name = "ipv6", + .type = QEMU_OPT_BOOL, + },{ .name = "password", .type = QEMU_OPT_BOOL, },{