From 39da58fb629167bfec4840764196170ae696f638 Mon Sep 17 00:00:00 2001 From: markt Date: Mon, 29 Mar 2010 11:51:46 +0000 Subject: [PATCH] Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=48840 If CDPATH is set, cd may result in output to stdout. Swallow the output. This is safe since the script outputs the value used for CATALINA_HOME so any issues will be visible then. Patch provided by mdietze git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@928732 13f79535-47bb-0310-9956-ffa450edef68 --- bin/catalina.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/catalina.sh b/bin/catalina.sh index 6f80cdb3f..46656f85c 100755 --- a/bin/catalina.sh +++ b/bin/catalina.sh @@ -105,7 +105,7 @@ done PRGDIR=`dirname "$PRG"` # Only set CATALINA_HOME if not already set -[ -z "$CATALINA_HOME" ] && CATALINA_HOME=`cd "$PRGDIR/.." ; pwd` +[ -z "$CATALINA_HOME" ] && CATALINA_HOME=`cd "$PRGDIR/.." >/dev/null 2>&1 ; pwd` # Ensure that any user defined CLASSPATH variables are not used on startup, # but allow them to be specified in setenv.sh, in rare case when it is needed. -- 2.11.0