From: Sven Velt Date: Tue, 23 Mar 2010 16:40:38 +0000 (+0100) Subject: Filter out host check if -D specified X-Git-Url: https://git.tokkee.org/?p=nagixsc.git;a=commitdiff_plain;h=ce2cb7aa270573b769affc707bb1e572716e8d76 Filter out host check if -D specified Signed-off-by: Sven Velt --- diff --git a/nagixsc/__init__.py b/nagixsc/__init__.py index 54a2125..ba96182 100644 --- a/nagixsc/__init__.py +++ b/nagixsc/__init__.py @@ -306,7 +306,8 @@ def xml_to_dict(xmldoc, verb=0, hostfilter=None, servicefilter=None): else: timestamp = filetimestamp - if retcode and output: + # Append only if no service filter + if not servicefilter and retcode and output: checks.append({'host_name':hostname, 'service_description':None, 'returncode':retcode, 'output':output, 'timestamp':timestamp})