Skip to contentSkip to conversation

policycoreutils: semanage: fix moduleRecords deleteall method

PATCH New Stephen Smalley 1 participant 1 message Jul 22, 2015 SELinux security module

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 policycoreutils: semanage: fix moduleRecords deleteall method

commit 2ff279e21e4715ac49e094b5fae8bc8e84b9e417 ("policycoreutils:
semanage: update to new source policy infrastructure") introduced
new methods for enabling/disabling modules but failed to update the deleteall method of class moduleRecords to use the new method. The deleteall method was introduced by commit 3dafb1046d847783f1e761535925ea79d69d3305 ("Add deleteall customizations field for modules.") as a way to re-enable all locally disabled modules.

---
 policycoreutils/semanage/seobject.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
policycoreutils/semanage/seobject.py +1 -1
index 2edb050..4c81a7b 100644
@@ -378,7 +378,7 @@ class moduleRecords(semanageRecords):
 	def deleteall(self):
                 l = map(lambda x: x[0], filter(lambda t: t[1] == 0, self.get_all()))
                 for m in l:
-                        self.enable(m)
+                        self.set_enabled(m, True)
 
 class dontauditClass(semanageRecords):
 	def __init__(self, store):
Signature · 1 line
2.1.0