diff options
author | Mattias Andrée <maandree@operamail.com> | 2013-11-18 17:50:44 +0100 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2013-11-18 17:50:44 +0100 |
commit | 6155eb0850b4c91a5e9a80dc230cb1d12d5c4f8c (patch) | |
tree | 6f0bad22560efd3f1ed0bb4f26f659c06a64c51d /src/security.c | |
parent | m + take ownership of and chmod /dev/vcs and /dev/vcsa (diff) | |
download | libpassphrase-6155eb0850b4c91a5e9a80dc230cb1d12d5c4f8c.tar.gz libpassphrase-6155eb0850b4c91a5e9a80dc230cb1d12d5c4f8c.tar.bz2 libpassphrase-6155eb0850b4c91a5e9a80dc230cb1d12d5c4f8c.tar.xz |
m
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to 'src/security.c')
-rw-r--r-- | src/security.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/security.c b/src/security.c index 1dc8c8c..33342fc 100644 --- a/src/security.c +++ b/src/security.c @@ -38,7 +38,7 @@ void secure_tty(void) int fd, i; /* Set ownership of this TTY to root:root */ - chown_tty(0, 0, 1); + chown_tty(0, -1, 1); /* Get TTY name for last part of this functions */ tty_device = ttyname(STDIN_FILENO); @@ -74,11 +74,11 @@ void secure_tty(void) /** * Set ownership and mode of the TTY * - * @param owner The owner - * @param group The group + * @param owner The owner, -1 for unchanged + * @param group The group, -1 for unchanged * @param with_fail Abort on failure */ -void chown_tty(int owner, int group, int with_fail) +void chown_tty(uid_t owner, gid_t group, int with_fail) { struct vt_stat vtstat; |