From: paulfantom Date: Wed, 13 Jul 2016 22:39:46 +0000 (+0200) Subject: fix postfix (no mails error) X-Git-Tag: v1.3.0~70^2~1 X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ca01e98cb87c6dd18f9ccede1e42495d85558236;p=netdata.git fix postfix (no mails error) --- diff --git a/plugins.d/python.d.plugin b/plugins.d/python.d.plugin index f5738e6e..bddcd6e5 100755 --- a/plugins.d/python.d.plugin +++ b/plugins.d/python.d.plugin @@ -484,6 +484,7 @@ def run(): # parse passed command line arguments modules = parse_cmdline(MODULES_DIR, *sys.argv) msg.DEBUG_FLAG = DEBUG_FLAG + modules = ['postfix'] msg.info("MODULES_DIR='" + MODULES_DIR + "', CONFIG_DIR='" + CONFIG_DIR + "', UPDATE_EVERY=" + str(BASE_CONFIG['update_every']) + diff --git a/python.d/python_modules/base.py b/python.d/python_modules/base.py index 077b6129..93467386 100644 --- a/python.d/python_modules/base.py +++ b/python.d/python_modules/base.py @@ -642,6 +642,9 @@ class ExecutableService(SimpleService): for line in p.stdout.readlines(): data.append(str(line.decode())) + if len(data) == 0: + return None + return data def check(self):