This is an automated email from Gerrit. Colin Baumgarten ([email protected]) just uploaded a new patch set to Gerrit, which you can find at http://openocd.zylin.com/3941
-- gerrit commit ba524293b8effde6736da86cd6b67473dcc24ef6 Author: Colin Baumgarten <[email protected]> Date: Fri Jan 6 00:15:26 2017 +0100 contrib/itmdump: fix two more compiler warnings Fix the following two warnings about write-only variables by simply removing them. itmdump.c: In function ‘show_timestamp’: itmdump.c:294:7: warning: variable ‘delayed’ set but not used [-Wunused-but-set-variable] bool delayed = false; ^ itmdump.c: In function ‘main’: itmdump.c:403:7: warning: variable ‘overflow’ set but not used [-Wunused-but-set-variable] bool overflow = false; ^ Change-Id: I4e1e4f10b76750354e39c916bd58ebe7a967d8af Signed-off-by: Colin Baumgarten <[email protected]> diff --git a/contrib/itmdump.c b/contrib/itmdump.c index 71f2a02..ff2a530 100644 --- a/contrib/itmdump.c +++ b/contrib/itmdump.c @@ -291,7 +291,6 @@ static void show_timestamp(FILE *f, int c) { unsigned counter = 0; char *label = ""; - bool delayed = false; if (dump_swit) return; @@ -323,15 +322,12 @@ static void show_timestamp(FILE *f, int c) break; case 0xd: label = ", timestamp delayed"; - delayed = true; break; case 0xe: label = ", packet delayed"; - delayed = true; break; case 0xf: label = ", packet and timetamp delayed"; - delayed = true; break; } @@ -400,7 +396,6 @@ int main(int argc, char **argv) /* Parse data ... records have a header then data bytes. * NOTE: we assume getc() deals in 8-bit bytes. */ - bool overflow = false; while ((c = getc(f)) != EOF) { @@ -430,11 +425,9 @@ bad_sync: /* REVISIT later, report just what overflowed! * Timestamp and SWIT can happen. Non-ITM too? */ - overflow = true; printf("OVERFLOW ...\n"); continue; } - overflow = false; switch (c & 0x0f) { case 0x00: /* Timestamp */ -- ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot _______________________________________________ OpenOCD-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/openocd-devel
