aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/lib.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/lib.c b/lib/lib.c
index 8937c57a..a6114321 100644
--- a/lib/lib.c
+++ b/lib/lib.c
@@ -1470,7 +1470,7 @@ void loggit(int priority, char *format, ...)
int i, facility = LOG_DAEMON;
va_list va;
- for (i = 0; i<3; i++) facility = LOG_AUTH;
+ for (i = 0; i<3; i++) if (isatty(i)) facility = LOG_AUTH;
openlog(toys.which->name, LOG_PID, facility);
va_start(va, format);
vsyslog(priority, format, va);