diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/jtag/jtag.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/src/jtag/jtag.c b/src/jtag/jtag.c index e8b66d15..12fff16c 100644 --- a/src/jtag/jtag.c +++ b/src/jtag/jtag.c @@ -257,15 +257,12 @@ int jtag_tap_count(void) unsigned jtag_tap_count_enabled(void) { - jtag_tap_t *t; - unsigned n; - - n = 0; - t = jtag_all_taps(); - while(t){ - if( t->enabled ){ + jtag_tap_t *t = jtag_all_taps(); + unsigned n = 0; + while(t) + { + if (t->enabled) n++; - } t = t->next_tap; } return n; |