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

[tor-commits] [tor/master] Name variables more consistently.



commit 8c9b4274255beb7b6397a4303fbb054fb55a4f11
Author: Linus Nordberg <linus@xxxxxxxxxxxxxx>
Date:   Fri Oct 19 23:23:04 2012 +0200

    Name variables more consistently.
---
 src/or/geoip.c    |   12 ++++++------
 src/or/or.h       |    2 +-
 src/or/policies.c |    2 +-
 3 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/or/geoip.c b/src/or/geoip.c
index 0097a7e..de8e280 100644
--- a/src/or/geoip.c
+++ b/src/or/geoip.c
@@ -1428,7 +1428,7 @@ static char *bridge_stats_extrainfo = NULL;
 char *
 geoip_format_bridge_stats(time_t now)
 {
-  char *out = NULL, *data = NULL, *ipver = NULL;
+  char *out = NULL, *country_data = NULL, *ipver_data = NULL;
   long duration = now - start_of_bridge_stats_interval;
   char written[ISO_TIME_LEN+1];
 
@@ -1438,17 +1438,17 @@ geoip_format_bridge_stats(time_t now)
     return NULL; /* Not initialized. */
 
   format_iso_time(written, now);
-  geoip_get_client_history(GEOIP_CLIENT_CONNECT, &data, &ipver);
+  geoip_get_client_history(GEOIP_CLIENT_CONNECT, &country_data, &ipver_data);
 
   tor_asprintf(&out,
                "bridge-stats-end %s (%ld s)\n"
                "bridge-ips %s\n"
                "bridge-ip-versions %s\n",
                written, duration,
-               data ? data : "",
-               ipver ? ipver : "");
-  tor_free(data);
-  tor_free(ipver);
+               country_data ? country_data : "",
+               ipver_data ? ipver_data : "");
+  tor_free(country_data);
+  tor_free(ipver_data);
 
   return out;
 }
diff --git a/src/or/or.h b/src/or/or.h
index 26b8973..5c6e998 100644
--- a/src/or/or.h
+++ b/src/or/or.h
@@ -3657,7 +3657,7 @@ typedef struct {
    * the bridge authority guess which countries have blocked access to us. */
   int BridgeRecordUsageByCountry;
 
-  /** Optionally, IPv4 and IPv6 GeoIP data */
+  /** Optionally, IPv4 and IPv6 GeoIP data. */
   char *GeoIPFile;
   char *GeoIPv6File;
 
diff --git a/src/or/policies.c b/src/or/policies.c
index 8187249..ecf1f68 100644
--- a/src/or/policies.c
+++ b/src/or/policies.c
@@ -323,7 +323,7 @@ addr_is_in_cc_list(uint32_t addr, const smartlist_t *cc_list)
 
   if (!cc_list)
     return 0;
-  /* XXX: ipv4 specific */
+  /* XXXXipv6 */
   tor_addr_from_ipv4h(&tar, addr);
   country = geoip_get_country_by_addr(&tar);
   name = geoip_get_country_name(country);



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