summaryrefslogtreecommitdiffstats
path: root/sesman/session.c
diff options
context:
space:
mode:
authorJay Sorg <jay.sorg@gmail.com>2014-11-13 22:08:14 -0800
committerJay Sorg <jay.sorg@gmail.com>2014-11-13 22:08:14 -0800
commit32f172853f9763f4b046c9e5465813a0aa5e3f1c (patch)
tree8f20d0d783696e680ac37725afb0e0a62f677f47 /sesman/session.c
parentddfd6b8b59ae411f15622ba4e50ef895b1e23e23 (diff)
parent942cdf300edaed7fee13a78e5e1c9b9c3d9c923e (diff)
downloadxrdp-proprietary-32f172853f9763f4b046c9e5465813a0aa5e3f1c.tar.gz
xrdp-proprietary-32f172853f9763f4b046c9e5465813a0aa5e3f1c.zip
Merge branch 'devel'
Diffstat (limited to 'sesman/session.c')
-rw-r--r--sesman/session.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/sesman/session.c b/sesman/session.c
index 856c969e..4ea48d35 100644
--- a/sesman/session.c
+++ b/sesman/session.c
@@ -460,6 +460,7 @@ session_start_fork(int width, int height, int bpp, char *username,
char screen[32];
char text[256];
char passwd_file[256];
+ char *pfile;
char **pp1 = (char **)NULL;
struct session_chain *temp = (struct session_chain *)NULL;
struct list *xserver_params = (struct list *)NULL;
@@ -633,10 +634,14 @@ session_start_fork(int width, int height, int bpp, char *username,
}
else if (xpid == 0) /* child */
{
- env_set_user(username, passwd_file, display,
+ pfile = 0;
+ if (type == SESMAN_SESSION_TYPE_XVNC)
+ {
+ pfile = passwd_file;
+ }
+ env_set_user(username, pfile, display,
g_cfg->session_variables1,
g_cfg->session_variables2);
- env_check_password_file(passwd_file, password);
g_snprintf(text, 255, "%d", g_cfg->sess.max_idle_time);
g_setenv("XRDP_SESMAN_MAX_IDLE_TIME", text, 1);
@@ -676,6 +681,7 @@ session_start_fork(int width, int height, int bpp, char *username,
}
else if (type == SESMAN_SESSION_TYPE_XVNC)
{
+ env_check_password_file(passwd_file, password);
xserver_params = list_create();
xserver_params->auto_free = 1;