[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH] qemu-char: fix warning 'res' may be used uninitiali
From: |
Igor Mammedov |
Subject: |
[Qemu-devel] [PATCH] qemu-char: fix warning 'res' may be used uninitialized |
Date: |
Wed, 25 Jun 2014 10:00:41 +0200 |
Signed-off-by: Igor Mammedov <address@hidden>
---
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
- [Qemu-devel] [PATCH] qemu-char: fix warning 'res' may be used uninitialized,
Igor Mammedov <=