From patchwork Sun Oct 2 16:53:09 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Weil X-Patchwork-Id: 117340 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [140.186.70.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id F24DDB6F7B for ; Mon, 3 Oct 2011 03:54:10 +1100 (EST) Received: from localhost ([::1]:58199 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RAPIm-0000LU-9Q for incoming@patchwork.ozlabs.org; Sun, 02 Oct 2011 12:54:08 -0400 Received: from eggs.gnu.org ([140.186.70.92]:40986) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RAPIg-0000L1-Qg for qemu-devel@nongnu.org; Sun, 02 Oct 2011 12:54:03 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RAPIf-0006aQ-Io for qemu-devel@nongnu.org; Sun, 02 Oct 2011 12:54:02 -0400 Received: from v220110690675601.yourvserver.net ([78.47.199.172]:46024) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RAPIf-0006Y1-EH; Sun, 02 Oct 2011 12:54:01 -0400 Received: from localhost (v220110690675601.yourvserver.net.local [127.0.0.1]) by v220110690675601.yourvserver.net (Postfix) with ESMTP id D4FFA728327C; Sun, 2 Oct 2011 18:53:38 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at weilnetz.de Received: from v220110690675601.yourvserver.net ([127.0.0.1]) by localhost (v220110690675601.yourvserver.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id h+p0VmgtBMOr; Sun, 2 Oct 2011 18:53:09 +0200 (CEST) Received: by v220110690675601.yourvserver.net (Postfix, from userid 1000) id 713ED7283278; Sun, 2 Oct 2011 18:53:09 +0200 (CEST) From: Stefan Weil To: qemu-devel@nongnu.org Date: Sun, 2 Oct 2011 18:53:09 +0200 Message-Id: <1317574389-15007-1-git-send-email-weil@mail.berlios.de> X-Mailer: git-send-email 1.7.2.5 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 78.47.199.172 Cc: qemu-trivial@nongnu.org Subject: [Qemu-devel] [PATCH] Fix mismatching allocation and deallocation 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 This error was reported by cppcheck. Signed-off-by: Stefan Weil --- console.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/console.c b/console.c index 6dfcc47..e43de92 100644 --- a/console.c +++ b/console.c @@ -1538,7 +1538,7 @@ int text_console_init(QemuOpts *opts, CharDriverState **_chr) } if (!s) { - free(chr); + g_free(chr); return -EBUSY; }