aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoger Dingledine <arma@torproject.org>2009-07-28 18:34:35 -0400
committerRoger Dingledine <arma@torproject.org>2009-07-28 18:34:35 -0400
commit6249b0fd7757293876549c58c6cfe351d44a1d11 (patch)
tree4293f7ae3079674caca3542fddf4af39407a33d7
parent69706f99e80aec9414e6a54e76346d4cf89f1a4c (diff)
downloadtor-6249b0fd7757293876549c58c6cfe351d44a1d11.tar
tor-6249b0fd7757293876549c58c6cfe351d44a1d11.tar.gz
Fix a signed/unsigned compile warning in 0.2.1.19
-rw-r--r--ChangeLog5
-rw-r--r--src/or/config.c8
-rw-r--r--src/or/or.h4
3 files changed, 11 insertions, 6 deletions
diff --git a/ChangeLog b/ChangeLog
index ed76e22f9..4fb38cf22 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Changes in version 0.2.1.20 - 2009-??-??
+ o Minor bugfixes:
+ - Fix a signed/unsigned compile warning in 0.2.1.19.
+
+
Changes in version 0.2.1.19 - 2009-07-28
o Major bugfixes:
- Make accessing hidden services on 0.2.1.x work right
diff --git a/src/or/config.c b/src/or/config.c
index 3f45b1e5e..fa986a6fc 100644
--- a/src/or/config.c
+++ b/src/or/config.c
@@ -1224,10 +1224,10 @@ options_need_geoip_info(or_options_t *options, const char **reason_out)
/** Return the bandwidthrate that we are going to report to the authorities
* based on the config options. */
-int
+uint32_t
get_effective_bwrate(or_options_t *options)
{
- int bw = (int)options->BandwidthRate;
+ uint32_t bw = (int)options->BandwidthRate;
if (bw > options->MaxAdvertisedBandwidth)
bw = (int)options->MaxAdvertisedBandwidth;
if (options->RelayBandwidthRate > 0 && bw > options->RelayBandwidthRate)
@@ -1237,10 +1237,10 @@ get_effective_bwrate(or_options_t *options)
/** Return the bandwidthburst that we are going to report to the authorities
* based on the config options. */
-int
+uint32_t
get_effective_bwburst(or_options_t *options)
{
- int bw = (int)options->BandwidthBurst;
+ uint32_t bw = (int)options->BandwidthBurst;
if (options->RelayBandwidthBurst > 0 && bw > options->RelayBandwidthBurst)
bw = (int)options->RelayBandwidthBurst;
return bw;
diff --git a/src/or/or.h b/src/or/or.h
index 1dcff28d6..319b3a9d1 100644
--- a/src/or/or.h
+++ b/src/or/or.h
@@ -2926,8 +2926,8 @@ int options_need_geoip_info(or_options_t *options, const char **reason_out);
int getinfo_helper_config(control_connection_t *conn,
const char *question, char **answer);
-int get_effective_bwrate(or_options_t *options);
-int get_effective_bwburst(or_options_t *options);
+uint32_t get_effective_bwrate(or_options_t *options);
+uint32_t get_effective_bwburst(or_options_t *options);
#ifdef CONFIG_PRIVATE
/* Used only by config.c and test.c */