From 980dbe99284ad35ff73732a878cee4551745b63f Mon Sep 17 00:00:00 2001 From: Lars Wirzenius Date: Sat, 26 Apr 2008 22:27:38 +0300 Subject: Ignore empty exclusion patterns, since they would match everything. --- obnam/app.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'obnam') diff --git a/obnam/app.py b/obnam/app.py index 284b6528..83b5d428 100644 --- a/obnam/app.py +++ b/obnam/app.py @@ -77,8 +77,9 @@ class Application: strings = config.getvalues("backup", "exclude") if self._exclusion_strings != strings: for string in strings: - logging.debug("Compiling exclusion pattern '%s'" % string) - self._exclusion_regexps.append(re.compile(string)) + if string: + logging.debug("Compiling exclusion pattern '%s'" % string) + self._exclusion_regexps.append(re.compile(string)) return self._exclusion_regexps -- cgit v1.2.1