From 39b71c52922779c56e21a9cd4ba94851466ab661 Mon Sep 17 00:00:00 2001 From: Daniel Beer Date: Sat, 22 May 2010 16:09:28 +1200 Subject: [PATCH] Fixed compilation warnings. --- rtools.c | 2 +- sim.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/rtools.c b/rtools.c index beb832a..dc21ff9 100644 --- a/rtools.c +++ b/rtools.c @@ -553,7 +553,7 @@ static int find_possible_edges(int offset, int len, uint8_t *memory, static int add_nodes_from_edges(struct call_graph *graph) { int i; - uint16_t last_addr; + uint16_t last_addr = 0; int have_last_addr = 0; qsort(graph->edge_from.ptr, graph->edge_from.size, diff --git a/sim.c b/sim.c index 8e84f7e..578f8b0 100644 --- a/sim.c +++ b/sim.c @@ -281,7 +281,7 @@ static int step_single(struct sim_device *dev, uint16_t ins) uint32_t mask = is_byte ? 0xff : 0xffff; uint16_t src_addr = 0; uint32_t src_data; - uint32_t res_data; + uint32_t res_data = 0; if (fetch_operand(dev, amode, reg, is_byte, &src_addr, &src_data) < 0) return -1;