diff options
author | Damien Miller <djm@mindrot.org> | 2020-06-26 15:30:06 +1000 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2020-06-26 15:30:06 +1000 |
commit | 32b2502a9dfdfded1ccdc1fd6dc2b3fe41bfc205 (patch) | |
tree | 8d46d19a64c554e86af54936a8f35bded680f622 /hostfile.c | |
parent | e073106f370cdd2679e41f6f55a37b491f0e82fe (diff) | |
download | openssh-git-32b2502a9dfdfded1ccdc1fd6dc2b3fe41bfc205.tar.gz |
missing ifdef SELINUX; spotted by dtucker
Diffstat (limited to 'hostfile.c')
-rw-r--r-- | hostfile.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -471,13 +471,17 @@ hostfile_create_user_ssh_dir(const char *filename, int notify) else if (errno != ENOENT) error("Could not stat %s: %s", dotsshdir, strerror(errno)); else { +#ifdef WITH_SELINUX ssh_selinux_setfscreatecon(dotsshdir); +#endif if (mkdir(dotsshdir, 0700) == -1) error("Could not create directory '%.200s' (%s).", dotsshdir, strerror(errno)); else if (notify) logit("Created directory '%s'.", dotsshdir); +#ifdef WITH_SELINUX ssh_selinux_setfscreatecon(NULL); +#endif } free(dotsshdir); } |