From c5e8bcc7e69cb300c5ec46f14855567f19745610 Mon Sep 17 00:00:00 2001 From: Cyril Jaquier Date: Sun, 1 Oct 2006 21:19:24 +0000 Subject: [PATCH] - Allow multiple log paths git-svn-id: https://fail2ban.svn.sourceforge.net/svnroot/fail2ban/trunk@393 a942ae1a-1317-0410-a47c-b1dcaea8d605 --- client/jailreader.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/client/jailreader.py b/client/jailreader.py index bf8dc431e..b5a36bdde 100644 --- a/client/jailreader.py +++ b/client/jailreader.py @@ -97,11 +97,12 @@ class JailReader(ConfigReader): stream = [["add", self.__name]] for opt in self.__opts: if opt == "logpath": - pathList = glob.glob(self.__opts[opt]) - if len(pathList) == 0: - logSys.error("No file found for " + self.__opts[opt]) - for path in pathList: - stream.append(["set", self.__name, "addlogpath", path]) + for path in self.__opts[opt].split("\n"): + pathList = glob.glob(path) + if len(pathList) == 0: + logSys.error("No file found for " + path) + for p in pathList: + stream.append(["set", self.__name, "addlogpath", p]) elif opt == "maxretry": stream.append(["set", self.__name, "maxretry", self.__opts[opt]]) elif opt == "ignoreip":