[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tor/master] Fix three -Wtautological-constant-out-of-range-compare warnings.



commit ded7e8093cad02c3acb53b4bb47083ae82b10b57
Author: Nick Mathewson <nickm@xxxxxxxxxxxxxx>
Date:   Thu Jun 30 14:08:28 2016 -0400

    Fix three -Wtautological-constant-out-of-range-compare warnings.
---
 src/or/networkstatus.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/or/networkstatus.c b/src/or/networkstatus.c
index 9968047..5415c30 100644
--- a/src/or/networkstatus.c
+++ b/src/or/networkstatus.c
@@ -1226,7 +1226,7 @@ networkstatus_get_dl_status_by_flavor,(consensus_flavor_t flavor))
   const int we_are_bootstrapping =
     networkstatus_consensus_is_bootstrapping(time(NULL));
 
-  if (flavor <= N_CONSENSUS_FLAVORS) {
+  if ((int)flavor <= N_CONSENSUS_FLAVORS) {
     dl = &((we_are_bootstrapping ?
            consensus_bootstrap_dl_status : consensus_dl_status)[flavor]);
   }
@@ -1241,7 +1241,7 @@ networkstatus_get_dl_status_by_flavor_bootstrap,(consensus_flavor_t flavor))
 {
   download_status_t *dl = NULL;
 
-  if (flavor <= N_CONSENSUS_FLAVORS) {
+  if ((int)flavor <= N_CONSENSUS_FLAVORS) {
     dl = &(consensus_bootstrap_dl_status[flavor]);
   }
 
@@ -1255,7 +1255,7 @@ networkstatus_get_dl_status_by_flavor_running,(consensus_flavor_t flavor))
 {
   download_status_t *dl = NULL;
 
-  if (flavor <= N_CONSENSUS_FLAVORS) {
+  if ((int)flavor <= N_CONSENSUS_FLAVORS) {
     dl = &(consensus_dl_status[flavor]);
   }
 

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits