aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rwxr-xr-xsrc/logging2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/logging b/src/logging
index 45e4815..8e8e14b 100755
--- a/src/logging
+++ b/src/logging
@@ -21,7 +21,7 @@
# Login username, client hostname if non-local, ttyname, cerberus-hook and PID
username=
hostname=
-ttyname="$(tty | cut -d / -f 1,2 --complement)"
+ttyname="$(tty <&2 | cut -d / -f 1,2 --complement)"
hook="${1}"
pid=$PPID
if [ ! "${LOGIN_PID}" = "" ]; then