|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH] libxl: stop libxl_domain_info() consuming massive amounts of stack
Paul Durrant writes ("[PATCH] libxl: stop libxl_domain_info() consuming massive
amounts of stack"):
> From: Paul Durrant <pdurrant@xxxxxxxxxx>
>
> Currently an array of 1024 xc_domaininfo_t is declared on stack. That alone
> consumes ~112k.
Wow.
> Since libxl_domain_info() creates a new gc this patch simply
> uses it to allocate the array instead.
Thanks.
> + info = libxl__calloc(gc, 1024, sizeof(*info));
Wy not GCNEW_ARRAY ?
That avoids a possible bug with wrong number of * to sizeof (although
in this case you seem to have it right...)
Thanks,
Ian.
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |