mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-30 15:43:32 +01:00
Fix tautological constant out-of-range comparison warnings.
This commit is contained in:
parent
a1e8ef0076
commit
64116ab97f
@ -540,7 +540,7 @@ consdiffmgr_find_consensus(struct consensus_cache_entry_t **entry_out,
|
|||||||
consensus_flavor_t flavor,
|
consensus_flavor_t flavor,
|
||||||
compress_method_t method)
|
compress_method_t method)
|
||||||
{
|
{
|
||||||
tor_assert(flavor < N_CONSENSUS_FLAVORS);
|
tor_assert((int)flavor < N_CONSENSUS_FLAVORS);
|
||||||
|
|
||||||
int pos = consensus_compression_method_pos(method);
|
int pos = consensus_compression_method_pos(method);
|
||||||
if (pos < 0) {
|
if (pos < 0) {
|
||||||
@ -1670,7 +1670,7 @@ consensus_compress_worker_replyfn(void *work_)
|
|||||||
|
|
||||||
unsigned u;
|
unsigned u;
|
||||||
consensus_flavor_t f = job->flavor;
|
consensus_flavor_t f = job->flavor;
|
||||||
tor_assert(f < N_CONSENSUS_FLAVORS);
|
tor_assert((int)f < N_CONSENSUS_FLAVORS);
|
||||||
for (u = 0; u < ARRAY_LENGTH(handles); ++u) {
|
for (u = 0; u < ARRAY_LENGTH(handles); ++u) {
|
||||||
if (handles[u] == NULL)
|
if (handles[u] == NULL)
|
||||||
continue;
|
continue;
|
||||||
|
Loading…
Reference in New Issue
Block a user