[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
[PATCH] make resetFileContext return the context set
- From: Will Woods <wwoods redhat com>
- To: anaconda-devel-list redhat com
- Cc:
- Subject: [PATCH] make resetFileContext return the context set
- Date: Fri, 1 May 2009 15:14:40 -0400
This patch makes resetFileContext return the context (a string)
on success, and None on failure. This fixes the "set SELinux
context for newly mounted ..." log messages to actually show
the context set.
---
isys/isys.py | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/isys/isys.py b/isys/isys.py
index 88bfaf1..0a3fe62 100755
--- a/isys/isys.py
+++ b/isys/isys.py
@@ -641,8 +641,9 @@ def setFileContext(fn, con, instroot = '/'):
def resetFileContext(fn, instroot = '/'):
con = matchPathContext(fn)
if con:
- return setFileContext(fn, con, instroot)
- return False
+ if setFileContext(fn, con, instroot):
+ return con
+ return None
def prefix2netmask(prefix):
return _isys.prefix2netmask(prefix)
--
1.6.2.2
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]