Received: from eggs.gnu.org ([2001:4830:134:3::10]:38362) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UmNfx-0001yv-AU for qemu-devel@nongnu.org; Tue, 11 Jun 2013 08:27:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UmNfw-0001o3-14 for qemu-devel@nongnu.org; Tue, 11 Jun 2013 08:27:49 -0400 Message-ID: <51B717C2.5050906@suse.de> Date: Tue, 11 Jun 2013 14:27:46 +0200 From: =?ISO-8859-15?Q?Andreas_F=E4rber?= MIME-Version: 1.0 References: <1370896852-12473-1-git-send-email-sw@weilnetz.de> In-Reply-To: <1370896852-12473-1-git-send-email-sw@weilnetz.de> Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH] target-sparc: Replace free by g_free List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefan Weil Cc: qemu-trivial , Blue Swirl , Michael Tokarev , qemu-devel Am 10.06.2013 22:40, schrieb Stefan Weil: > The wrong function was reported by cppcheck. >=20 > Signed-off-by: Stefan Weil Reviewed-by: Andreas F=E4rber > --- > target-sparc/cpu.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) >=20 > diff --git a/target-sparc/cpu.c b/target-sparc/cpu.c > index 290b580..13bb7bb 100644 > --- a/target-sparc/cpu.c > +++ b/target-sparc/cpu.c > @@ -614,7 +614,7 @@ static int cpu_sparc_find_by_name(sparc_def_t *cpu_= def, const char *cpu_model) > return 0; > =20 > error: > - free(s); > + g_free(s); > return -1; > } > =20 So s is for the string, and matches occurrence above, fine. Andreas --=20 SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N=FCrnberg, Germany GF: Jeff Hawn, Jennifer Guild, Felix Imend=F6rffer; HRB 16746 AG N=FCrnbe= rg