[Pkg-mono-svn-commits] [SCM] xsp branch, master-experimental, updated. debian/2.6.5-1

Jo Shields directhex at apebox.org
Mon Aug 9 01:16:20 UTC 2010


The following commit has been merged in the master-experimental branch:
commit f73de0f821a78bd7216fd40c73c7cf40167f1b17
Author: Jo Shields <directhex at apebox.org>
Date:   Mon Aug 9 01:33:11 2010 +0100

    If /etc/default/mono-xspX is missing, then don't die in postinst (LP: #563383)

diff --git a/debian/changelog b/debian/changelog
index 23ac389..e788934 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -7,6 +7,10 @@ xsp (2.6.5-1) UNRELEASED; urgency=low
     + Make daemon enabled or disabled on the basis of the start_boot value 
       of /etc/default/mono-xspX. As a side effect of this, the init script 
       will no longer die horribly if the default file is missing or junk.
+  * debian/mono-xsp1.postinst,
+    debian/mono-xsp2.postinst:
+    + If /etc/default/mono-xspX is missing, then don't die in postinst
+      (LP: #563383)
 
  -- Jo Shields <directhex at apebox.org>  Sat, 07 Aug 2010 20:36:51 +0100
 
diff --git a/debian/mono-xsp1.postinst b/debian/mono-xsp1.postinst
index c64909d..096cb3d 100644
--- a/debian/mono-xsp1.postinst
+++ b/debian/mono-xsp1.postinst
@@ -32,6 +32,9 @@ should_start() {
         if [ "$start_boot" != "true" ]; then
 	    return 1
         fi
+    else
+        echo "mono-xsp1: Not started, you need a valid and complete $xsp_default"
+        return 1
     fi
 
     if [ ! -e $VIRTUALFILE -o `cat $VIRTUALFILE | wc -l` = "2" ]; then
@@ -72,9 +75,11 @@ case "$1" in
 	    update-rc.d -f mono-xsp1 remove > /dev/null 2>&1  || true
 	fi
 
-	# Configure the port and address
-	update_port
-	update_bind
+	# If default file exists, configure the port and address
+	if [ -f $xsp_default ]; then
+	    update_port
+	    update_bind
+	fi
 
 	# chmod the working directories
 	chown -R www-data:www-data /var/run/mono-xsp1
diff --git a/debian/mono-xsp2.postinst b/debian/mono-xsp2.postinst
index 79a30ae..497ff8d 100644
--- a/debian/mono-xsp2.postinst
+++ b/debian/mono-xsp2.postinst
@@ -32,6 +32,9 @@ should_start() {
         if [ "$start_boot" != "true" ]; then
 	    return 1
         fi
+    else
+        echo "mono-xsp2: Not started, you need a valid and complete $xsp2_default"
+        return 1
     fi
 
     if [ ! -e $VIRTUALFILE -o `cat $VIRTUALFILE | wc -l` = "2" ]; then
@@ -71,9 +74,11 @@ case "$1" in
 	    update-rc.d -f mono-xsp2 remove > /dev/null 2>&1  || true
 	fi
 
-	# Configure the port and address
-	update_port
-	update_bind
+	# If default file exists, configure the port and address
+	if [ -f $xsp2_default ]; then
+	    update_port
+	    update_bind
+	fi
 
 	# chmod the working directories
 	chown -R www-data:www-data /var/run/mono-xsp2

-- 
xsp



More information about the Pkg-mono-svn-commits mailing list