summaryrefslogtreecommitdiff
path: root/src/svf
diff options
context:
space:
mode:
authorZachary T Welch <zw@superlucidity.net>2009-11-10 00:02:18 -0800
committerZachary T Welch <zw@superlucidity.net>2009-11-13 10:55:27 -0800
commitd22270e0ed291d3b08fd03a25181b279ca5e0911 (patch)
treee9467fb7e4a05043d18eb747d0b4bfd89511abf1 /src/svf
parenta585bdf7269ce5c861c83ee3294ba1f074e9c877 (diff)
downloadopenocd_libswd-d22270e0ed291d3b08fd03a25181b279ca5e0911.tar.gz
openocd_libswd-d22270e0ed291d3b08fd03a25181b279ca5e0911.tar.bz2
openocd_libswd-d22270e0ed291d3b08fd03a25181b279ca5e0911.tar.xz
openocd_libswd-d22270e0ed291d3b08fd03a25181b279ca5e0911.zip
command_handler_t: make argc unsigned
The number of command arguments will always be 0 or more, so use the right type in handlers. This has a cascading effect up through the layers, but the new COMMAND_HANDLER macros prevented total chaos.
Diffstat (limited to 'src/svf')
-rw-r--r--src/svf/svf.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/svf/svf.c b/src/svf/svf.c
index 76b06704..8f2ee80c 100644
--- a/src/svf/svf.c
+++ b/src/svf/svf.c
@@ -304,7 +304,7 @@ int svf_add_statemove(tap_state_t state_to)
COMMAND_HANDLER(handle_svf_command)
{
#define SVF_NUM_OF_OPTIONS 1
- int command_num = 0, i;
+ int command_num = 0;
int ret = ERROR_OK;
long long time_ago;
@@ -316,7 +316,7 @@ COMMAND_HANDLER(handle_svf_command)
// parse variant
svf_quiet = 0;
- for (i = 1; i < argc; i++)
+ for (unsigned i = 1; i < argc; i++)
{
if (!strcmp(args[i], "quiet"))
{