From: Øyvind Harboe Date: Mon, 24 Oct 2011 16:11:43 +0000 (+0200) Subject: warning: silence gcc by initializing local variables X-Git-Tag: v0.6.0-rc1~504 X-Git-Url: https://review.openocd.org/gitweb?p=openocd.git;a=commitdiff_plain;h=e5fd6131fe781631797631ba8ba48cf361ff7635;ds=sidebyside warning: silence gcc by initializing local variables GCC doesn't understand that these are in fact initialized if they are used. Change-Id: I01988adb0547f785b48d869ddbe44cc17dca4739 Signed-off-by: Øyvind Harboe Reviewed-on: http://openocd.zylin.com/116 Tested-by: jenkins Reviewed-by: Øyvind Harboe --- diff --git a/src/target/arm_adi_v5.c b/src/target/arm_adi_v5.c index 7f89f2eed9..9ea7b5a145 100644 --- a/src/target/arm_adi_v5.c +++ b/src/target/arm_adi_v5.c @@ -1352,7 +1352,7 @@ static int dap_info_command(struct command_context *cmd_ctx, struct adiv5_dap *dap, int ap) { int retval; - uint32_t dbgbase, apid; + uint32_t dbgbase = 0, apid = 0; /* Silence gcc by initializing */ int romtable_present = 0; uint8_t mem_ap; uint32_t ap_old;