From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42403) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Wzi8X-0000xN-Il for qemu-devel@nongnu.org; Wed, 25 Jun 2014 04:01:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Wzi8Q-0008FM-3t for qemu-devel@nongnu.org; Wed, 25 Jun 2014 04:00:57 -0400 From: Igor Mammedov Date: Wed, 25 Jun 2014 10:00:41 +0200 Message-Id: <1403683241-20678-1-git-send-email-imammedo@redhat.com> Subject: [Qemu-devel] [PATCH] qemu-char: fix warning 'res' may be used uninitialized List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: qemu-trivial@nongnu.org, peter.maydell@linaro.org Signed-off-by: Igor Mammedov --- 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