qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
To: qemu-devel@nongnu.org
Cc: Anthony Liguori <aliguori@us.ibm.com>,
	Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>,
	Pavel Borzenkov <pavel.borzenkov@gmail.com>
Subject: [Qemu-devel] [PATCH 03/10] vmdk: vmdk_read_cid returns garbage if p_name is NULL
Date: Wed, 26 Oct 2011 15:22:06 +0100	[thread overview]
Message-ID: <1319638933-19063-4-git-send-email-stefanha@linux.vnet.ibm.com> (raw)
In-Reply-To: <1319638933-19063-1-git-send-email-stefanha@linux.vnet.ibm.com>

From: Pavel Borzenkov <pavel.borzenkov@gmail.com>

Spotted by Clang Analyzer

Signed-off-by: Pavel Borzenkov <pavel.borzenkov@gmail.com>
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
---
 block/vmdk.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/block/vmdk.c b/block/vmdk.c
index 3969131..a75dcc2 100644
--- a/block/vmdk.c
+++ b/block/vmdk.c
@@ -207,7 +207,7 @@ static void vmdk_free_last_extent(BlockDriverState *bs)
 static uint32_t vmdk_read_cid(BlockDriverState *bs, int parent)
 {
     char desc[DESC_SIZE];
-    uint32_t cid;
+    uint32_t cid = 0xffffffff;
     const char *p_name, *cid_str;
     size_t cid_str_size;
     BDRVVmdkState *s = bs->opaque;
-- 
1.7.7

  parent reply	other threads:[~2011-10-26 14:22 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-26 14:22 [Qemu-devel] [PULL 00/10] Trivial patches for October 15 to 26 2011 Stefan Hajnoczi
2011-10-26 14:22 ` [Qemu-devel] [PATCH 01/10] device_tree: Fix potential memory leak Stefan Hajnoczi
2011-10-26 14:22 ` [Qemu-devel] [PATCH 02/10] vmdk: remove unneeded variable assignment Stefan Hajnoczi
2011-10-26 14:22 ` Stefan Hajnoczi [this message]
2011-10-26 14:22 ` [Qemu-devel] [PATCH 04/10] qed: don't pass NULL to memcpy Stefan Hajnoczi
2011-10-26 14:22 ` [Qemu-devel] [PATCH 05/10] qed: remove unneeded variable assignment Stefan Hajnoczi
2011-10-26 14:22 ` [Qemu-devel] [PATCH 06/10] exec.c: Remove useless comment Stefan Hajnoczi
2011-10-26 14:22 ` [Qemu-devel] [PATCH 07/10] tools: reorganize Makefile variables Stefan Hajnoczi
2011-10-26 14:22 ` [Qemu-devel] [PATCH 08/10] Fix typo: buf -> bus Stefan Hajnoczi
2011-10-26 14:22 ` [Qemu-devel] [PATCH 09/10] Documentation: fix typo Stefan Hajnoczi
2011-10-26 14:22 ` [Qemu-devel] [PATCH 10/10] ahci: fix DPRINTF format strings Stefan Hajnoczi
2011-10-31 16:52 ` [Qemu-devel] [PULL 00/10] Trivial patches for October 15 to 26 2011 Anthony Liguori

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=1319638933-19063-4-git-send-email-stefanha@linux.vnet.ibm.com \
    --to=stefanha@linux.vnet.ibm.com \
    --cc=aliguori@us.ibm.com \
    --cc=pavel.borzenkov@gmail.com \
    --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).