qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Kevin Wolf <kwolf@redhat.com>
To: qemu-block@nongnu.org
Cc: kwolf@redhat.com, ashijeetacharya@gmail.com, pl@kamp.de,
	qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH for-2.8] nfs: Fix memory leak in nfs_file_create()
Date: Mon,  7 Nov 2016 10:31:29 +0100	[thread overview]
Message-ID: <1478511089-8210-1-git-send-email-kwolf@redhat.com> (raw)

The leak was introduced in commit 94d6a7a7.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
---
 block/nfs.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/block/nfs.c b/block/nfs.c
index 55c4e0b..d082783 100644
--- a/block/nfs.c
+++ b/block/nfs.c
@@ -676,6 +676,7 @@ static int nfs_file_create(const char *url, QemuOpts *opts, Error **errp)
     ret = nfs_ftruncate(client->context, client->fh, total_size);
     nfs_client_close(client);
 out:
+    QDECREF(options);
     g_free(client);
     return ret;
 }
-- 
1.8.3.1

             reply	other threads:[~2016-11-07  9:31 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-07  9:31 Kevin Wolf [this message]
2016-11-07 13:36 ` [Qemu-devel] [Qemu-block] [PATCH for-2.8] nfs: Fix memory leak in nfs_file_create() Stefan Hajnoczi

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=1478511089-8210-1-git-send-email-kwolf@redhat.com \
    --to=kwolf@redhat.com \
    --cc=ashijeetacharya@gmail.com \
    --cc=pl@kamp.de \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.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).