qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Luiz Capitulino <lcapitulino@redhat.com>
To: qemu-trivial <qemu-trivial@nongnu.org>
Cc: qemu-devel@nongnu.org
Subject: [Qemu-devel] [TRIVIAL] virtio_cleanup(): Remove unneeded g_free() parameter check
Date: Thu, 9 Feb 2012 11:29:42 -0200	[thread overview]
Message-ID: <20120209112942.77ce62bf@doriath.home> (raw)


Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
---
 hw/virtio.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/hw/virtio.c b/hw/virtio.c
index 74cc038..064aecf 100644
--- a/hw/virtio.c
+++ b/hw/virtio.c
@@ -845,8 +845,7 @@ int virtio_load(VirtIODevice *vdev, QEMUFile *f)
 void virtio_cleanup(VirtIODevice *vdev)
 {
     qemu_del_vm_change_state_handler(vdev->vmstate);
-    if (vdev->config)
-        g_free(vdev->config);
+    g_free(vdev->config);
     g_free(vdev->vq);
     g_free(vdev);
 }
-- 
1.7.9.111.gf3fb0.dirty

             reply	other threads:[~2012-02-09 13:30 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-09 13:29 Luiz Capitulino [this message]
2012-02-09 15:28 ` [Qemu-devel] [Qemu-trivial] [TRIVIAL] virtio_cleanup(): Remove unneeded g_free() parameter check Stefan Hajnoczi
2012-02-09 15:48   ` Luiz Capitulino

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=20120209112942.77ce62bf@doriath.home \
    --to=lcapitulino@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-trivial@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).