clear whitelist, if it gets cleard.
parent
5af250398c
commit
9b02c9272e
|
@ -391,11 +391,15 @@ def whitelistUpdate():
|
||||||
while not quit_now:
|
while not quit_now:
|
||||||
start_time = time.time()
|
start_time = time.time()
|
||||||
list = r.hgetall('F2B_WHITELIST')
|
list = r.hgetall('F2B_WHITELIST')
|
||||||
|
|
||||||
|
gen_whitelist = []
|
||||||
|
|
||||||
if list:
|
if list:
|
||||||
new_whitelist = genNetworkList(list)
|
gen_whitelist = genNetworkList(list)
|
||||||
if Counter(new_whitelist) != Counter(WHITELIST):
|
|
||||||
WHITELIST = new_whitelist
|
if Counter(gen_whitelist) != Counter(WHITELIST):
|
||||||
logInfo('New entrys for whitelist %s' % WHITELIST)
|
WHITELIST = gen_whitelist
|
||||||
|
logInfo('New entrys for whitelist %s' % WHITELIST)
|
||||||
|
|
||||||
time.sleep(60.0 - ((time.time() - start_time) % 60.0))
|
time.sleep(60.0 - ((time.time() - start_time) % 60.0))
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue