Removed self.rules != old_rules

After lot of testing it does not work properly. Could do something more
sophisticated but since calling save() is safe and probably lightweigth it is
not worth probably.
This commit is contained in:
donoban 2018-03-08 05:25:42 -05:00
父節點 6e8e48e32d
當前提交 39d904ea82
沒有發現已知的金鑰在資料庫的簽署中
GPG 金鑰 ID: 141310D8E3ED08A5

查看文件

@ -546,12 +546,10 @@ class Firewall(object):
def _expire_rules(self):
'''Function called to reload expired rules'''
old_rules = self.rules
self.load()
if self.rules != old_rules:
# this will both save rules skipping those expired and trigger
# QubesDB update; and possibly schedule another timer
self.save()
# this will both save rules skipping those expired and trigger
# QubesDB update; and possibly schedule another timer
self.save()
def save(self):
'''Save firewall rules to a file'''