From: Christoph Egger Subject: Re: [PATCH] fix build error in libxl Date: Mon, 3 Jan 2011 14:40:08 +0100 Message-ID: <201101031440.09061.Christoph.Egger@amd.com> References: <749B9D3DBF0F054390025D9EAFF47F223195EEB1@shsmsx501.ccr.corp.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <749B9D3DBF0F054390025D9EAFF47F223195EEB1@shsmsx501.ccr.corp.intel.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 Cc: "Zhang, Yang Z" , Keir Fraser List-Id: xen-devel@lists.xenproject.org On Thursday 23 December 2010 03:08:38 Zhang, Yang Z wrote: > Move free(disks) into the bracket, or it will show error 'disks' used > uninitialized when build libxl. I have the same build problem. My patch is very similar: http://lists.xensource.com/archives/html/xen-devel/2010-12/msg01011.html Christoph > > best regards > yang > > diff -r f69037cc4674 tools/libxl/libxl.c > --- a/tools/libxl/libxl.c Wed Dec 22 17:48:31 2010 +0000 > +++ b/tools/libxl/libxl.c Thu Dec 23 10:03:35 2010 +0800 > @@ -1402,8 +1402,8 @@ > } > libxl_device_disk_destroy(&disks[i]); > } > + free(disks); > } > - free(disks); > flexarray_set(dm_args, num++, NULL); > return (char **) flexarray_contents(dm_args); > } > > > > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xensource.com > http://lists.xensource.com/xen-devel -- ---to satisfy European Law for business letters: Advanced Micro Devices GmbH Einsteinring 24, 85609 Dornach b. Muenchen Geschaeftsfuehrer: Alberto Bozzo, Andrew Bowd Sitz: Dornach, Gemeinde Aschheim, Landkreis Muenchen Registergericht Muenchen, HRB Nr. 43632