You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2019/05/30 15:12:47 UTC
[tomcat] 01/02: Use test -t command to check if STDOUT is opened on
a terminal
This is an automated email from the ASF dual-hosted git repository.
markt pushed a commit to branch 8.5.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git
commit f1709cad1cffc3352cb440e69529e44e5473646c
Author: Radosław Józwik <ti...@spelunca.net>
AuthorDate: Tue May 21 23:11:59 2019 +0200
Use test -t command to check if STDOUT is opened on a terminal
---
bin/catalina.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/bin/catalina.sh b/bin/catalina.sh
index 5a8c2b5..55fd90b 100755
--- a/bin/catalina.sh
+++ b/bin/catalina.sh
@@ -228,7 +228,7 @@ fi
# Bugzilla 37848: When no TTY is available, don't output to console
have_tty=0
-if [ "`tty`" != "not a tty" ]; then
+if [ -t 1 ]; then
have_tty=1
fi
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org