diff options
author | Matt Johnston <matt@ucc.asn.au> | 2011-04-07 11:18:35 +0000 |
---|---|---|
committer | Matt Johnston <matt@ucc.asn.au> | 2011-04-07 11:18:35 +0000 |
commit | 4e3c39d055232cee6183f63d746e00f6cd7a74ff (patch) | |
tree | 242f0242ec1d95dff8e4b5b387ccbe7bb49c3d38 | |
parent | fae213b746483c01d519cac8c5c28ea20a4325f2 (diff) | |
download | dropbear-4e3c39d055232cee6183f63d746e00f6cd7a74ff.tar.gz |
Change comparison to be more paranoid (and perhaps avoid Klocwork false
positive). Does not change behaviour.
-rw-r--r-- | cli-algo.c | 2 | ||||
-rw-r--r-- | svr-algo.c | 2 |
2 files changed, 2 insertions, 2 deletions
@@ -67,7 +67,7 @@ algo_type * cli_buf_match_algo(buffer* buf, algo_type localalgos[], remotealgos[count] = &algolist[i+1]; count++; } - if (count == MAX_PROPOSED_ALGO) { + if (count >= MAX_PROPOSED_ALGO) { break; } } @@ -68,7 +68,7 @@ algo_type * svr_buf_match_algo(buffer* buf, algo_type localalgos[], remotealgos[count] = &algolist[i+1]; count++; } - if (count == MAX_PROPOSED_ALGO) { + if (count >= MAX_PROPOSED_ALGO) { break; } } |