mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2025-02-18 17:00:24 +00:00
misc/simulators/ringsim.py: fix LGTM nit
We haven't used this tool for a decade, but LGTM flagged a static-analysis warning. Fixing it to see if the LGTM dashboard is looking at new builds.
This commit is contained in:
parent
0964bc0d05
commit
f155ade4ad
@ -38,9 +38,9 @@ def abbreviate_space(s, SI=True):
|
|||||||
|
|
||||||
def make_up_a_file_size(seed):
|
def make_up_a_file_size(seed):
|
||||||
h = int(myhash(seed).hexdigest(),16)
|
h = int(myhash(seed).hexdigest(),16)
|
||||||
if 1: # exponential distribution
|
# exponential distribution
|
||||||
e = 8 + (h % (31-8))
|
e = 8 + (h % (31-8))
|
||||||
return 2 ** e
|
return 2 ** e
|
||||||
# uniform distribution
|
# uniform distribution
|
||||||
#max=2**31
|
#max=2**31
|
||||||
#return h % max # avg 1GB
|
#return h % max # avg 1GB
|
||||||
|
Loading…
x
Reference in New Issue
Block a user