xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Andrew Cooper <andrew.cooper3@citrix.com>
To: Ian Jackson <Ian.Jackson@eu.citrix.com>
Cc: George Dunlap <george.dunlap@eu.citrix.com>,
	Ian Campbell <Ian.Campbell@citrix.com>,
	xen-devel@lists.xen.org
Subject: Re: [PATCH] tools/libxc: Fix memory leaks in xc_domain_restore()
Date: Fri, 21 Jun 2013 18:30:25 +0100	[thread overview]
Message-ID: <51C48DB1.2030800@citrix.com> (raw)
In-Reply-To: <20932.36093.15692.139649@mariner.uk.xensource.com>

On 21/06/13 18:27, Ian Jackson wrote:
> Andrew Cooper writes ("[PATCH] tools/libxc: Fix memory leaks in xc_domain_restore()"):
>> tools/libxc: Fix memory leaks in xc_domain_restore()
>> +    free(region_mfn);
> ...
>> +    pagebuf_free(&pagebuf);
> These look correct to me.
>
> But as regards
>
>> +    free(ctx->p2m_batch);
> It's not clear to me where that's initialised.  It needs to be
> initialised to NULL I think.
>
> Ian.

It is initialised in memset(ctx, 0, sizeof(*ctx)) at the top of the
function.

~Andrew

  reply	other threads:[~2013-06-21 17:30 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-21 16:36 [PATCH] tools/libxc: Fix memory leaks in xc_domain_restore() Andrew Cooper
2013-06-21 17:27 ` Ian Jackson
2013-06-21 17:30   ` Andrew Cooper [this message]
2013-06-24 13:12     ` [PATCH] tools/libxc: Fix memory leaks in xc_domain_restore() [and 1 more messages] Ian Jackson
2013-06-24 10:19 ` [PATCH] tools/libxc: Fix memory leaks in xc_domain_restore() George Dunlap

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=51C48DB1.2030800@citrix.com \
    --to=andrew.cooper3@citrix.com \
    --cc=Ian.Campbell@citrix.com \
    --cc=Ian.Jackson@eu.citrix.com \
    --cc=george.dunlap@eu.citrix.com \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).