[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH 08/13 v5] libxl: don't leak ptr in libxl_list_vm error case [and 1 more messages]



Ian Campbell writes ("Re: [PATCH 08/13 v5] libxl: don't leak ptr in 
libxl_list_vm error case"):
> On Tue, 2013-12-03 at 14:29 +1300, Matthew Daley wrote:
> > +    /*
> > +  * Always make sure to allocate at least one element; if we don't and we
> > +  * request zero, libxl__calloc (might) think its internal call to calloc
> > +  * has failed (if it returns null), if so it would kill our process.
[rewrapped -iwj]
> 
> Is size==0 something we could/should handle in our libxl__*alloc
> wrappers?

I think so.  I think they should promise that if you pass size==0 you
get a non-null pointer.  Calling realloc with size==0 should crash.

Matthew Daley writes ("Re: [PATCH 08/13 v5] libxl: don't leak ptr in 
libxl_list_vm error case"):
> Ping?

See Ian C's comment above, which AFAICT hasn't been answered.

Thanks,
Ian.

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.