From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:41948) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aXlup-0006kW-7o for qemu-devel@nongnu.org; Mon, 22 Feb 2016 03:32:24 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aXluj-0005Sw-9y for qemu-devel@nongnu.org; Mon, 22 Feb 2016 03:32:23 -0500 Received: from mx1.redhat.com ([209.132.183.28]:44915) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aXluj-0005Ss-4O for qemu-devel@nongnu.org; Mon, 22 Feb 2016 03:32:17 -0500 Received: from int-mx13.intmail.prod.int.phx2.redhat.com (int-mx13.intmail.prod.int.phx2.redhat.com [10.5.11.26]) by mx1.redhat.com (Postfix) with ESMTPS id A64472DC37F for ; Mon, 22 Feb 2016 08:32:16 +0000 (UTC) From: Gerd Hoffmann Date: Mon, 22 Feb 2016 09:32:10 +0100 Message-Id: <1456129930-27222-2-git-send-email-kraxel@redhat.com> In-Reply-To: <1456129930-27222-1-git-send-email-kraxel@redhat.com> References: <1456129930-27222-1-git-send-email-kraxel@redhat.com> Subject: [Qemu-devel] [PULL 1/1] gtk: fix uninitialized temporary VirtualConsole List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Paolo Bonzini , Gerd Hoffmann From: Paolo Bonzini Only the echo field is used in the temporary VirtualConsole, so the damage was limited. But still, if echo was incorrectly set to true, the result would be some puzzling output in VTE monitor and serial consoles. Fixes: fba958c692e47a373d15c1fd3d72b255bf76adbd Cc: Gerd Hoffmann Tested-by: Mark Cave-Ayland Signed-off-by: Paolo Bonzini Message-id: 1455015557-15106-2-git-send-email-pbonzini@redhat.com Signed-off-by: Gerd Hoffmann --- ui/gtk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/gtk.c b/ui/gtk.c index 2b46965..3773826 100644 --- a/ui/gtk.c +++ b/ui/gtk.c @@ -1613,7 +1613,7 @@ static CharDriverState *gd_vc_handler(ChardevVC *vc, Error **errp) chr->chr_set_echo = gd_vc_chr_set_echo; /* Temporary, until gd_vc_vte_init runs. */ - chr->opaque = g_new(VirtualConsole, 1); + chr->opaque = g_new0(VirtualConsole, 1); /* defer OPENED events until our vc is fully initialized */ chr->explicit_be_open = true; -- 1.8.3.1