diff options
author | oharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60> | 2009-04-19 20:51:16 +0000 |
---|---|---|
committer | oharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60> | 2009-04-19 20:51:16 +0000 |
commit | 40580e2d71ac56131a5da7e5f67a0b63450e4f24 (patch) | |
tree | e35583cefe3a40bfdc0cd2456565f273369b4a3f /src/svf | |
parent | 7989000e0969c1ccf69acbc3ce649a020bc1ee66 (diff) | |
download | riscv-openocd-40580e2d71ac56131a5da7e5f67a0b63450e4f24.zip riscv-openocd-40580e2d71ac56131a5da7e5f67a0b63450e4f24.tar.gz riscv-openocd-40580e2d71ac56131a5da7e5f67a0b63450e4f24.tar.bz2 |
Zach Welch <zw@superlucidity.net> fix -Werror warnings
git-svn-id: svn://svn.berlios.de/openocd/trunk@1472 b42882b7-edfa-0310-969c-e2dbd0fdcd60
Diffstat (limited to 'src/svf')
-rw-r--r-- | src/svf/svf.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/svf/svf.c b/src/svf/svf.c index f1a52da..01e5631 100644 --- a/src/svf/svf.c +++ b/src/svf/svf.c @@ -103,7 +103,7 @@ const char *svf_trst_mode_name[4] = "ABSENT" }; -char *svf_tap_state_name[16]; +char *svf_tap_state_name[TAP_NUM_STATES]; #define XXR_TDI (1 << 0) #define XXR_TDO (1 << 1) @@ -316,7 +316,7 @@ static int handle_svf_command(struct command_context_s *cmd_ctx, char *cmd, char svf_buffer_size = 2 * SVF_MAX_BUFFER_SIZE_TO_COMMIT; memcpy(&svf_para, &svf_para_init, sizeof(svf_para)); - for (i = 0; i < dimof(svf_tap_state_name); i++) + for (i = 0; i < (int)dimof(svf_tap_state_name); i++) { svf_tap_state_name[i] = (char *)tap_state_name(i); } @@ -515,7 +515,7 @@ static int svf_tap_state_is_stable(tap_state_t state) static int svf_tap_state_is_valid(tap_state_t state) { - return ((state >= 0) && (state < sizeof(svf_tap_state_name))); + return state >= 0 && state < TAP_NUM_STATES; } static int svf_find_string_in_array(char *str, char **strs, int num_of_element) |