From 5ac49193adab92efc08c3c94c3e6bd483ce7d0f1 Mon Sep 17 00:00:00 2001 From: Coty Sutherland Date: Sep 26 2019 16:00:56 +0000 Subject: Resolves: rhbz#1466026 JVM options are duplicated after service restart --- diff --git a/tomcat-7.0.init b/tomcat-7.0.init index 026adb9..dd737e8 100644 --- a/tomcat-7.0.init +++ b/tomcat-7.0.init @@ -75,6 +75,9 @@ TOMCAT_LOG="${TOMCAT_LOG:-${CATALINA_HOME}/logs/${NAME}-initd.log}" # Define the tomcat pid file CATALINA_PID="${CATALINA_PID:-/var/run/${NAME}.pid}" +# Variable to keep parseOptions status +OPTIONS_PARSED="0" + RETVAL="0" # Look for open ports, as the function name might imply @@ -142,7 +145,10 @@ function parseOptions() { /etc/sysconfig/${NAME} )" fi - TOMCAT_SCRIPT="$options ${TOMCAT_SCRIPT}" + if [ "$OPTIONS_PARSED" -eq 0 ]; then + TOMCAT_SCRIPT="$options ${TOMCAT_SCRIPT}" + OPTIONS_PARSED=1 + fi } # See how we were called. diff --git a/tomcat.spec b/tomcat.spec index a70b170..3ee9115 100644 --- a/tomcat.spec +++ b/tomcat.spec @@ -53,7 +53,7 @@ Name: tomcat Epoch: 0 Version: %{major_version}.%{minor_version}.%{micro_version} -Release: 1%{?dist} +Release: 2%{?dist} Summary: Apache Servlet/JSP Engine, RI for Servlet %{servletspec}/JSP %{jspspec} API Group: System Environment/Daemons @@ -616,6 +616,9 @@ fi %{_sbindir}/%{name}-jsvc %changelog +* Thu Sep 26 2019 Coty Sutherland - 1:7.0.94-2 +- Resolves: rhbz#1466026 JVM options are duplicated after service restart + * Tue Jun 18 2019 Coty Sutherland - 1:7.0.94-1 - Update to 7.0.94 - Resolves: rhbz#1713280 - CVE-2019-0221 tomcat: XSS in SSI printenv