[PATCH 2/4] x86emu: Silence compiler warnings.
Cyril Brulebois
kibi at debian.org
Sun Jun 5 10:58:13 PDT 2011
Both if/else match, so usage of ip32 or ip16 will only happen after the
proper one has been initialized.
As a consequence, let's silence those warnings by initializing both
variables to 0:
| CC ops.lo
| ops.c: In function 'x86emuOp_call_near_IMM':
| ops.c:9701:39: warning: 'ip32' may be used uninitialized in this function [-Wuninitialized]
| ops.c:9704:39: warning: 'ip16' may be used uninitialized in this function [-Wuninitialized]
Signed-off-by: Cyril Brulebois <kibi at debian.org>
---
hw/xfree86/x86emu/ops.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/hw/xfree86/x86emu/ops.c b/hw/xfree86/x86emu/ops.c
index 5d3cac1..792c65a 100644
--- a/hw/xfree86/x86emu/ops.c
+++ b/hw/xfree86/x86emu/ops.c
@@ -9679,8 +9679,8 @@ Handles opcode 0xe8
****************************************************************************/
static void x86emuOp_call_near_IMM(u8 X86EMU_UNUSED(op1))
{
- s16 ip16;
- s32 ip32;
+ s16 ip16 = 0;
+ s32 ip32 = 0;
START_OF_INSTR();
DECODE_PRINTF("CALL\t");
--
1.7.5.3
More information about the xorg-devel
mailing list