aboutsummaryrefslogtreecommitdiff
path: root/Linux-PAM/modules/pam_namespace/pam_namespace.c
diff options
context:
space:
mode:
authorSteve Langasek <steve.langasek@ubuntu.com>2019-01-03 16:09:38 -0800
committerSteve Langasek <steve.langasek@ubuntu.com>2019-01-03 16:09:38 -0800
commit03398c56c56ed427818d2ce879d45d1009f7d46b (patch)
tree9a7bc0d7d15ac988ac9ad31ad18a769030faced7 /Linux-PAM/modules/pam_namespace/pam_namespace.c
parente78677298d54010c3a62b932baefdae152fd0fed (diff)
parent281e859131adad49301befbc50cfc5cd282c6937 (diff)
downloadpam-03398c56c56ed427818d2ce879d45d1009f7d46b.tar.gz
pam-03398c56c56ed427818d2ce879d45d1009f7d46b.tar.bz2
pam-03398c56c56ed427818d2ce879d45d1009f7d46b.zip
merge upstream version 0.99.9.0
Diffstat (limited to 'Linux-PAM/modules/pam_namespace/pam_namespace.c')
-rw-r--r--Linux-PAM/modules/pam_namespace/pam_namespace.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/Linux-PAM/modules/pam_namespace/pam_namespace.c b/Linux-PAM/modules/pam_namespace/pam_namespace.c
index 73d8e591..d3612f59 100644
--- a/Linux-PAM/modules/pam_namespace/pam_namespace.c
+++ b/Linux-PAM/modules/pam_namespace/pam_namespace.c
@@ -589,8 +589,9 @@ static int poly_name(const struct polydir_s *polyptr, char **i_name,
#ifdef WITH_SELINUX
*i_context = NULL;
*origcon = NULL;
- if ((rc=form_context(polyptr, i_context, origcon, idata)) != PAM_SUCCESS) {
- return rc;
+ if ((idata->flags & PAMNS_SELINUX_ENABLED) &&
+ (rc=form_context(polyptr, i_context, origcon, idata)) != PAM_SUCCESS) {
+ return rc;
}
#endif