All of lore.kernel.org
 help / color / mirror / Atom feed
From: Igor Mammedov <imammedo@redhat.com>
To: qemu-devel@nongnu.org
Cc: qemu-trivial@nongnu.org, peter.maydell@linaro.org
Subject: [Qemu-devel] [PATCH] qemu-char: fix warning 'res' may be used uninitialized
Date: Wed, 25 Jun 2014 10:00:41 +0200	[thread overview]
Message-ID: <1403683241-20678-1-git-send-email-imammedo@redhat.com> (raw)

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
---
 qemu-char.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/qemu-char.c b/qemu-char.c
index 2e50a10..f6bdf2f 100644
--- a/qemu-char.c
+++ b/qemu-char.c
@@ -132,7 +132,7 @@ int qemu_chr_fe_write(CharDriverState *s, const uint8_t *buf, int len)
 int qemu_chr_fe_write_all(CharDriverState *s, const uint8_t *buf, int len)
 {
     int offset = 0;
-    int res;
+    int res = 0;
 
     qemu_mutex_lock(&s->chr_write_lock);
     while (offset < len) {
-- 
1.7.1

             reply	other threads:[~2014-06-25  8:01 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-25  8:00 Igor Mammedov [this message]
2014-06-25  9:08 ` [Qemu-devel] [PATCH] qemu-char: fix warning 'res' may be used uninitialized Markus Armbruster
2014-06-25 11:51   ` Igor Mammedov
2014-06-25 19:10     ` Stefan Weil
2014-06-26 12:03       ` Peter Maydell

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=1403683241-20678-1-git-send-email-imammedo@redhat.com \
    --to=imammedo@redhat.com \
    --cc=peter.maydell@linaro.org \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.