[apache2] 01/01: Fixed tests on deferred mpm switch (#789914)

Jean-Michel Vourgère nirgal at moszumanska.debian.org
Mon Jul 20 13:30:09 UTC 2015


This is an automated email from the git hooks/post-receive script.

nirgal pushed a commit to branch master
in repository apache2.

commit 60dfe3d656aaecad281288e77d45e0fee9b3d919
Author: Jean-Michel Vourgère <nirgal at debian.org>
Date:   Mon Jul 20 15:29:40 2015 +0200

    Fixed tests on deferred mpm switch (#789914)
---
 debian/apache2.postinst | 14 +++++++-------
 debian/changelog        |  2 ++
 2 files changed, 9 insertions(+), 7 deletions(-)

diff --git a/debian/apache2.postinst b/debian/apache2.postinst
index e4863bd..1342a74 100644
--- a/debian/apache2.postinst
+++ b/debian/apache2.postinst
@@ -151,21 +151,21 @@ execute_deferred_actions ()
 			esac
 			;;
 		apache2_switch_mpm)
-			local MPM="mpm_$ARG1"
+			local MPM="$ARG1"
 			local CUR_MPM="$(ls /etc/apache2/mods-enabled/mpm_*.load)"
 			CUR_MPM="${CUR_MPM##*/mpm_}"
 			CUR_MPM="${CUR_MPM%.load}"
-			if [ ! -e /etc/apache2/mods-available/$MPM.load ] ; then
-				msg "error" "$MPM not found in 'apache2_switch_mpm $ARG1' for package $PACKAGE"
+			if [ ! -e /etc/apache2/mods-available/mpm_$MPM.load ] ; then
+				msg "error" "mpm $MPM not found in 'apache2_switch_mpm $ARG1' for package $PACKAGE"
 				error=true
-			elif [ ! -e /etc/apache2/mods-enabled/$MPM.load ] ; then
-				msg "info" "$MPM: No action required"
+			elif [ -e /etc/apache2/mods-enabled/mpm_$MPM.load ] ; then
+				msg "info" "Switch to mpm $MPM for package $PACKAGE: No action required"
 			else
-				msg "info" "Switch to $MPM for package $PACKAGE"
+				msg "info" "Switch to mpm $MPM for package $PACKAGE"
 				if ! a2dismod -m -q "mpm_$CUR_MPM" ||
 				   ! a2enmod -m -q "mpm_$MPM"
 				then
-					msg "error" "Switching to $MPM failed"
+					msg "error" "Switching to mpm $MPM failed"
 					error=true
 				fi
 			fi
diff --git a/debian/changelog b/debian/changelog
index c7b7a54..a273fcf 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -12,6 +12,8 @@ apache2 (2.4.12-3) UNRELEASED; urgency=medium
     links there for dynamic loading.
   * Upgrade security.conf comments to 2.4 auth format. Thanks Werner
     Detter. Closes: #789788
+  * apache2.postinst: Fixed tests on deferred mpm switch. Closes:
+    #789914
 
  -- Jean-Michel Vourgère <nirgal at debian.org>  Thu, 28 May 2015 16:20:59 +0200
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-apache/apache2.git



More information about the Pkg-apache-commits mailing list