From: "Peter Teoh" Subject: Re: Xenstored: eliminate double free and fixes for memory leak Date: Mon, 17 Sep 2007 15:07:51 +0800 Message-ID: <804dabb00709170007j3051fe7ahde41205423735499@mail.gmail.com> References: <804dabb00709161919n6eb52d5apcb3aaff5f20e42bc@mail.gmail.com> <804dabb00709162248i756de19eh1397e5075937fe95@mail.gmail.com> <804dabb00709162254h4be27710gbeb807a8c7f24a3@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <804dabb00709162254h4be27710gbeb807a8c7f24a3@mail.gmail.com> Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org On top of abovementioned problems I missed out this one: canonicalize() may return an existing pointer as a value - so no memory deallocation is needed, but it also may return a newly allocated memory - for which deallocation is needed. And currently all the results returned from canonicalize() are not freed. Please let me know how to fix this. Thanks.