moved copy into for loop

This commit is contained in:
f-kessler 2019-03-14 12:07:32 +01:00 committed by GitHub
parent 07a69d5e26
commit b1170668b2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -73,12 +73,12 @@ def processAlarm(typ, freq, data):
logging.debug("[ ALARM ]")
# timestamp, to make sure, that all plugins use the same time
data['timestamp'] = int(time.time())
# copy objects to avoid issues if the objects will be changed by the plugin's during runtime and during asynch/threaded processing
dctyp = deepcopy(typ)
dcfreq = deepcopy(freq)
dcdata = deepcopy(data)
# Go to all plugins in pluginList
for pluginName, plugin in globalVars.pluginList.items():
# copy objects to avoid issues if the objects will be changed by the plugin's during runtime and during asynch/threaded processing
dctyp = deepcopy(typ)
dcfreq = deepcopy(freq)
dcdata = deepcopy(data)
# if enabled use RegEx-filter
if globalVars.config.getint("BOSWatch","useRegExFilter"):
from includes import regexFilter