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

Re: [Xen-devel] [PATCH 15/15] libxl: do not leak an event struct on ignored ao progress



On Wed, 2012-05-30 at 17:16 +0100, Ian Jackson wrote:
> On entry to libxl__ao_progress_report, the caller has allocated an
> event.  If the progress report is to be ignored, we need to free it.
> 
> Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>

Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx>

> ---
>  tools/libxl/libxl_event.c |    1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)
> 
> diff --git a/tools/libxl/libxl_event.c b/tools/libxl/libxl_event.c
> index 565d2c2..dd1a9ca 100644
> --- a/tools/libxl/libxl_event.c
> +++ b/tools/libxl/libxl_event.c
> @@ -1601,6 +1601,7 @@ void libxl__ao_progress_report(libxl__egc *egc, 
> libxl__ao *ao,
>      ev->for_user = how->for_event;
>      if (how->callback == dummy_asyncprogress_callback_ignore) {
>          LOG(DEBUG,"ao %p: progress report: ignored",ao);
> +        libxl_event_free(CTX,ev);
>          /* ignore */
>      } else if (how->callback) {
>          libxl__aop_occurred *aop = libxl__zalloc(&egc->gc, sizeof(*aop));



_______________________________________________
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®.