From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60410) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XLwgJ-00050v-3P for qemu-devel@nongnu.org; Mon, 25 Aug 2014 11:59:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XLwgC-0002SS-EV for qemu-devel@nongnu.org; Mon, 25 Aug 2014 11:59:43 -0400 Received: from mx1.redhat.com ([209.132.183.28]:38852) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XLwgC-0002SH-6r for qemu-devel@nongnu.org; Mon, 25 Aug 2014 11:59:36 -0400 Date: Mon, 25 Aug 2014 23:59:28 +0800 From: Amos Kong Message-ID: <20140825155928.GA1925@zen> References: <1407349101-27793-1-git-send-email-ehabkost@redhat.com> <1407349101-27793-2-git-send-email-ehabkost@redhat.com> <20140807022412.GB8109@z.redhat.com> <53E35287.1070608@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <53E35287.1070608@redhat.com> Subject: Re: [Qemu-devel] [PATCH RESEND 1/2] rng-egd: Free old chr_name value before setting new one List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: Markus Armbruster , Eduardo Habkost , Anthony Liguori , qemu-devel@nongnu.org On Thu, Aug 07, 2014 at 12:18:47PM +0200, Paolo Bonzini wrote: > Il 07/08/2014 04:24, Amos Kong ha scritto: > > Eduardo, a similar patch had been applied. > > > > commit 5e490b6a504912225dff0e520e1c6af68295d238 > > Author: Amos Kong > > Date: Thu Nov 21 16:42:50 2013 +0800 > > > > rng-egd: remove redundant free > > > > We didn't set default chr_name, the free is redundant. > > > > Signed-off-by: Amos Kong > > Message-id: 1385023371-8198-2-git-send-email-akong@redhat.com > > Signed-off-by: Anthony Liguori > > > > What if you set chr_name twice? In this case, g_free() is necessary. So I'm fine with Eduardo's patch: [PATCH RESEND 1/2] rng-egd: Free old chr_name value > Paolo -- Amos.