diff options
author | Dean Jansa <djansa@redhat.com> | 2008-06-27 16:28:54 +0000 |
---|---|---|
committer | Nathan Straz <nstraz@redhat.com> | 2008-09-23 09:37:47 -0400 |
commit | 055c473f917703e7e73581a915e770f595dd76b4 (patch) | |
tree | 183736e8c1be3582d7c09697c7c24437ecbdfaf9 /qarshd.c | |
parent | 423ad02026a37dc128e0b879cadf9dbaf6377af7 (diff) | |
download | qarsh-055c473f917703e7e73581a915e770f595dd76b4.tar.gz qarsh-055c473f917703e7e73581a915e770f595dd76b4.tar.xz qarsh-055c473f917703e7e73581a915e770f595dd76b4.zip |
Nate made a good point, we should not fail if we can't chdir. ssh warns, but lets you in. Don't bother checking the return of chdir().
Diffstat (limited to 'qarshd.c')
-rw-r--r-- | qarshd.c | 6 |
1 files changed, 1 insertions, 5 deletions
@@ -71,11 +71,7 @@ setup_user(char *user, char *group) /* setuid is last so we can still do setgid and initgroups */ setuid(pw->pw_uid); - if (chdir(pw->pw_dir) < 0) { - syslog(LOG_WARNING, "Unable to chdir() to %s: %s\n", - pw->pw_dir, strerror(errno)); - return 0; - } + if (pw->pw_dir) chdir(pw->pw_dir); return 1; } |