From a14c7c1af0c7f4de51db922aba1d61addfe5747f Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Sat, 1 Sep 2018 16:58:53 +0200 Subject: T731: fix use of uninitialized value in concatenation --- scripts/vyatta-log-commit.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'scripts') diff --git a/scripts/vyatta-log-commit.pl b/scripts/vyatta-log-commit.pl index bbf0852..7927500 100644 --- a/scripts/vyatta-log-commit.pl +++ b/scripts/vyatta-log-commit.pl @@ -21,7 +21,7 @@ # Portions created by Vyatta are Copyright (C) 2010 Vyatta, Inc. # All Rights Reserved. # -# Author: Deepti Kulkarni +# Author: Deepti Kulkarni # Date: Feb 2012 # Description: Script to log active configuration commits to syslog. # @@ -40,7 +40,7 @@ my $status = $ENV{'COMMIT_STATUS'}; my $commit_status = 'Successful' if ($status eq 'SUCCESS'); #open log for logging commit details if (defined $commit_status) { - my $cur_tty = ttyname(0); + my $cur_tty = POSIX::ttyname(0) || "unknown"; my $cur_user = getlogin() || getpwuid($<) || "unknown"; openlog("commit", "", LOG_USER); -- cgit v1.2.3