From a9a7ba9da3c67766bf27f462bd4d32c0dd2caa6c Mon Sep 17 00:00:00 2001 From: "Chris St. Pierre" Date: Mon, 27 Aug 2012 20:59:49 -0400 Subject: POSIX: fixed setting handled entries --- src/lib/Bcfg2/Client/Tools/POSIX/__init__.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/lib/Bcfg2/Client/Tools/POSIX/__init__.py b/src/lib/Bcfg2/Client/Tools/POSIX/__init__.py index 46631eb06..6316c749c 100644 --- a/src/lib/Bcfg2/Client/Tools/POSIX/__init__.py +++ b/src/lib/Bcfg2/Client/Tools/POSIX/__init__.py @@ -32,9 +32,14 @@ class POSIX(Bcfg2.Client.Tools.Tool): # need to do it again after __handles__ has been populated. we # can't populate __handles__ when the class is created because # _load_handlers() _must_ be called at run-time, not at - # compile-time. + # compile-time. This also has to _extend_ self.handled, not + # set it, because self.handled has some really crazy + # semi-global thing going that, frankly, scares the crap out + # of me. for struct in config: - self.handled = [e for e in struct if self.handlesEntry(e)] + self.handled.extend([e for e in struct + if (e not in self.handled and + self.handlesEntry(e))]) def _load_handlers(self): # this must be called at run-time, not at compile-time, or we -- cgit v1.2.3-1-g7c22