From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id E56A21388C1 for ; Thu, 3 Mar 2016 13:03:24 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 364B721C00F; Thu, 3 Mar 2016 13:03:22 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 8CCCCE0826 for ; Thu, 3 Mar 2016 13:03:21 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id C707D340BDA for ; Thu, 3 Mar 2016 13:03:20 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id ECDB92091 for ; Thu, 3 Mar 2016 13:03:16 +0000 (UTC) From: "Lars Wendler" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Lars Wendler" Message-ID: <1457009186.889c598ac4275caf37f2f9473f6947b4b4d7c0fe.polynomial-c@gentoo> Subject: [gentoo-commits] proj/apache:master commit in: 2.4/init/ X-VCS-Repository: proj/apache X-VCS-Files: 2.4/init/apache2.initd X-VCS-Directories: 2.4/init/ X-VCS-Committer: polynomial-c X-VCS-Committer-Name: Lars Wendler X-VCS-Revision: 889c598ac4275caf37f2f9473f6947b4b4d7c0fe X-VCS-Branch: master Date: Thu, 3 Mar 2016 13:03:16 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 38196b25-05a7-429f-aedc-a5672b8ee4c3 X-Archives-Hash: fa96c4dfae76d391dfa2e6e547d1ebc0 commit: 889c598ac4275caf37f2f9473f6947b4b4d7c0fe Author: Michael Orlitzky gentoo org> AuthorDate: Thu Jan 21 15:25:46 2016 +0000 Commit: Lars Wendler gentoo org> CommitDate: Thu Mar 3 12:46:26 2016 +0000 URL: https://gitweb.gentoo.org/proj/apache.git/commit/?id=889c598a apache2.initd: set the path to the apache2 binary once, globally. The $APACHE2 variable (containing the path to apache2) is currently set every time checkconfd() is called. Its value never changes, and the variable is already global, so we might as well set it once at the beginning of the script. 2.4/init/apache2.initd | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/2.4/init/apache2.initd b/2.4/init/apache2.initd index 50b6500..c9d12c7 100755 --- a/2.4/init/apache2.initd +++ b/2.4/init/apache2.initd @@ -22,6 +22,9 @@ SERVERROOT="${SERVERROOT:-/usr/lib/apache2}" CONFIGFILE="${CONFIGFILE:-/etc/apache2/httpd.conf}" RELOAD_TYPE="${RELOAD_TYPE:-graceful}" +# The path to the apache2 binary. +APACHE2="/usr/sbin/apache2" + depend() { need net use mysql dns logger netmount postgresql @@ -44,7 +47,6 @@ checkconfd() { APACHE2_OPTS="${APACHE2_OPTS} -f ${CONFIGFILE}" [ -n "${STARTUPERRORLOG}" ] && APACHE2_OPTS="${APACHE2_OPTS} -E ${STARTUPERRORLOG}" - APACHE2="/usr/sbin/apache2" } checkconfig() {