]> granicus.if.org Git - shadow/commitdiff
* libmisc/chowntty.c: Only closelog() when failure cause an exit.
authornekral-guest <nekral-guest@5a98b0ae-9ef6-0310-add3-de5d479b70d7>
Sun, 23 Nov 2008 00:06:56 +0000 (00:06 +0000)
committernekral-guest <nekral-guest@5a98b0ae-9ef6-0310-add3-de5d479b70d7>
Sun, 23 Nov 2008 00:06:56 +0000 (00:06 +0000)
ChangeLog
libmisc/chowntty.c

index 18c1ee12683fbdcec6583087c7bc64ae417657a3..b278bcb90c55981e47cfb689152e02d7ca51aabd 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -2,6 +2,7 @@
 
        * libmisc/chowntty.c: Improve the logs for fchown and fchmod
        failures.
+       * libmisc/chowntty.c: Only closelog() when failure cause an exit.
 
 2008-11-23  Nicolas François  <nicolas.francois@centraliens.net>
 
index b43931e320702f4ac852ed5eea460eb8313d7b47..3d4da1074b5a6fd36bf6d0dd3be57a8be43b1ead 100644 (file)
@@ -90,6 +90,7 @@ void chown_tty (const struct passwd *info)
                         "unable to change owner or mode of tty stdin for user `%s': %s\n",
                         info->pw_name, strerror (err)));
                if (EROFS != err) {
+                       closelog ();
                        exit (1);
                }
        }