[CRIU] [PATCH 1/4] lsm: Remove write-only lsm name variable

Pavel Emelyanov xemul at virtuozzo.com
Mon Jun 26 16:19:53 MSK 2017


Signed-off-by: Pavel Emelyanov <xemul at virtuozzo.com>
---
 criu/lsm.c | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/criu/lsm.c b/criu/lsm.c
index 4f5c436..acdb1fb 100644
--- a/criu/lsm.c
+++ b/criu/lsm.c
@@ -21,7 +21,6 @@
 
 static Lsmtype	lsmtype;
 static int	(*get_label)(pid_t, char **) = NULL;
-static char	*name = NULL;
 
 static int apparmor_get_label(pid_t pid, char **profile_name)
 {
@@ -120,7 +119,6 @@ void kerndat_lsm(void)
 	if (access(AA_SECURITYFS_PATH, F_OK) == 0) {
 		get_label = apparmor_get_label;
 		lsmtype = LSMTYPE__APPARMOR;
-		name = "apparmor";
 		return;
 	}
 
@@ -133,14 +131,12 @@ void kerndat_lsm(void)
 	if (access("/sys/fs/selinux", F_OK) == 0) {
 		get_label = selinux_get_label;
 		lsmtype = LSMTYPE__SELINUX;
-		name = "selinux";
 		return;
 	}
 #endif
 
 	get_label = NULL;
 	lsmtype = LSMTYPE__NO_LSM;
-	name = "none";
 }
 
 Lsmtype host_lsm_type(void)
-- 
2.1.4



More information about the CRIU mailing list