WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] [PATCH 0 of 3] libxl: leak in uuid to string conversions

To: Gianni Tedesco <gianni.tedesco@xxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH 0 of 3] libxl: leak in uuid to string conversions
From: Ian Campbell <Ian.Campbell@xxxxxxxxxx>
Date: Mon, 16 Aug 2010 14:06:23 +0100
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>, Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
Delivery-date: Mon, 16 Aug 2010 06:07:10 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <1281963100.18490.371.camel@xxxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Organization: Citrix Systems, Inc.
References: <patchbomb.1281709807@xxxxxxxxxxxxxxxxxxxxx> <19557.25054.889868.859565@xxxxxxxxxxxxxxxxxxxxxxxx> <1281963100.18490.371.camel@xxxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
On Mon, 2010-08-16 at 13:51 +0100, Gianni Tedesco wrote:
> On Fri, 2010-08-13 at 16:16 +0100, Ian Jackson wrote:
> > Ian Campbell writes ("[Xen-devel] [PATCH 0 of 3] libxl: leak in uuid to 
> > string conversions"):
> > > Fix a few memory leaks in the functions which convert uuids into
> > > strings.
> > 
> > Acked-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
> > 
> > (all three)
> > 
> > Ian.
> 
> I'm not sure I agree with this patch, especially 3 of 3. The callers are
> inconsistent and also pointless. There's no need to allocate a uuid
> string when all that's really needed is a few printf macros as in
> "[PATCH,v2] xl: make libxl_uuid2string internal to libxenlight" - Also
> UUID_FMT remains duplicated.
> 
> The first two patches are probably fine but then we should just nuke
> libxl_uuid2string all together. Such a function makes sense for libxl
> where it's going to be constructing xenstore paths so may need to keep
> such things around but xl has no use for this as far as I can see.

FWIW the reason I didn't followup further with this thread (other than
it being a Friday afternoon) was that I agreed with your v2 patch which
added the macros and made the libxl_uuid2string fn internal to the
library. AFAICT your patch also solved all the leaks I was seeing.

Ian.


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel