diff options
author | Colin Watson <cjwatson@debian.org> | 2016-08-06 10:49:58 +0100 |
---|---|---|
committer | Colin Watson <cjwatson@debian.org> | 2016-08-06 10:49:58 +0100 |
commit | a8ed8d256b2e2c05b0c15565a7938028c5192277 (patch) | |
tree | 87abbdc914a38b43e4e5bb9581ad1f46eabbf88e /platform.c | |
parent | f0329aac23c61e1a5197d6d57349a63f459bccb0 (diff) | |
parent | 99522ba7ec6963a05c04a156bf20e3ba3605987c (diff) |
Import openssh_7.3p1.orig.tar.gz
Diffstat (limited to 'platform.c')
-rw-r--r-- | platform.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/platform.c b/platform.c index ee313da55..acf8554cd 100644 --- a/platform.c +++ b/platform.c | |||
@@ -18,8 +18,6 @@ | |||
18 | 18 | ||
19 | #include "includes.h" | 19 | #include "includes.h" |
20 | 20 | ||
21 | #include <sys/types.h> | ||
22 | |||
23 | #include <stdarg.h> | 21 | #include <stdarg.h> |
24 | #include <unistd.h> | 22 | #include <unistd.h> |
25 | 23 | ||
@@ -107,8 +105,12 @@ platform_setusercontext(struct passwd *pw) | |||
107 | #endif | 105 | #endif |
108 | 106 | ||
109 | #ifdef USE_SOLARIS_PROJECTS | 107 | #ifdef USE_SOLARIS_PROJECTS |
110 | /* if solaris projects were detected, set the default now */ | 108 | /* |
111 | if (getuid() == 0 || geteuid() == 0) | 109 | * If solaris projects were detected, set the default now, unless |
110 | * we are using PAM in which case it is the responsibility of the | ||
111 | * PAM stack. | ||
112 | */ | ||
113 | if (!options.use_pam && (getuid() == 0 || geteuid() == 0)) | ||
112 | solaris_set_default_project(pw); | 114 | solaris_set_default_project(pw); |
113 | #endif | 115 | #endif |
114 | 116 | ||