commit dcddc95dc3480016957e1f831f44d3a70aa95f7b Author: Mike Perry mikeperry-git@fscked.org Date: Sun Dec 11 12:01:04 2011 -0800
And it's INT32_MAX, not UINT32_MAX..
Too bad python doesn't seem to have constants for either? --- NetworkScanners/BwAuthority/aggregate.py | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/NetworkScanners/BwAuthority/aggregate.py b/NetworkScanners/BwAuthority/aggregate.py index b655db7..15d8d82 100755 --- a/NetworkScanners/BwAuthority/aggregate.py +++ b/NetworkScanners/BwAuthority/aggregate.py @@ -735,9 +735,9 @@ def main(argv):
# Go through the list and cap them to NODE_CAP for n in nodes.itervalues(): - if n.new_bw >= 0xffffffff: + if n.new_bw >= 0x7fffffff: plog("WARN", "Bandwidth of node "+n.nick+"="+n.idhex+" exceeded maxint32: "+str(n.new_bw)) - n.new_bw = 0xffffffff + n.new_bw = 0x7fffffff if cs_junk.T_i > 0 and cs_junk.T_i_decay > 0 \ and math.fabs(n.pid_error_sum) > \ math.fabs(2*cs_junk.T_i*n.pid_error/cs_junk.T_i_decay):
tor-commits@lists.torproject.org