diff options
author | Balint Reczey <balint@balintreczey.hu> | 2021-11-07 15:18:49 +0100 |
---|---|---|
committer | Balint Reczey <balint@balintreczey.hu> | 2021-11-07 15:18:49 +0100 |
commit | 749c1780621163ca5108f164861324bafa9e0ae8 (patch) | |
tree | 51001872624a692018c45bf39276df94b603fb19 /libmisc/chowntty.c | |
parent | d906ecd3b652d95af6ffb974a2f6669501bb9496 (diff) | |
download | shadow-749c1780621163ca5108f164861324bafa9e0ae8.tar.gz |
New upstream version 4.9upstream/4.9
Diffstat (limited to 'libmisc/chowntty.c')
-rw-r--r-- | libmisc/chowntty.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libmisc/chowntty.c b/libmisc/chowntty.c index f6f5dbc5..a42ab622 100644 --- a/libmisc/chowntty.c +++ b/libmisc/chowntty.c @@ -62,6 +62,7 @@ void chown_tty (const struct passwd *info) grent = getgr_nam_gid (getdef_str ("TTYGROUP")); if (NULL != grent) { gid = grent->gr_gid; + gr_free (grent); } else { gid = info->pw_gid; } @@ -75,7 +76,7 @@ void chown_tty (const struct passwd *info) || (fchmod (STDIN_FILENO, (mode_t)getdef_num ("TTYPERM", 0600)) != 0)) { int err = errno; - fprintf (stderr, + fprintf (shadow_logfd, _("Unable to change owner or mode of tty stdin: %s"), strerror (err)); SYSLOG ((LOG_WARN, |