[Initscripts-ng-commits] r544 - in /trunk/src/insserv/debian: changelog patches/00list patches/46_complete_removal.dpatch run-testsuite

pere at users.alioth.debian.org pere at users.alioth.debian.org
Sat Jan 19 13:44:13 UTC 2008


Author: pere
Date: Sat Jan 19 13:44:12 2008
New Revision: 544

URL: http://svn.debian.org/wsvn/initscripts-ng/?sc=1&rev=544
Log:
  * Make sure to remove all symlinks on removal (Closes: #460034).
    Based on patch from Kel Modderman.  Made failing removal test
    fatal.

Added:
    trunk/src/insserv/debian/patches/46_complete_removal.dpatch   (with props)
Modified:
    trunk/src/insserv/debian/changelog
    trunk/src/insserv/debian/patches/00list
    trunk/src/insserv/debian/run-testsuite

Modified: trunk/src/insserv/debian/changelog
URL: http://svn.debian.org/wsvn/initscripts-ng/trunk/src/insserv/debian/changelog?rev=544&op=diff
==============================================================================
--- trunk/src/insserv/debian/changelog (original)
+++ trunk/src/insserv/debian/changelog Sat Jan 19 13:44:12 2008
@@ -1,4 +1,4 @@
-insserv (1.10.0-6) UNRELEASED; urgency=low
+insserv (1.10.0-6) UN RELEASED; urgency=low
 
   * Implement support for preseeding insserv, to make it possible to
     enable it at install time.  This only work the first time the
@@ -8,6 +8,9 @@
     /etc/insserv.conf (Closes: #459522)
   * Extend testsuite to more closely match real Debian for the
     shutdown sequence.
+  * Make sure to remove all symlinks on removal (Closes: #460034).
+    Based on patch from Kel Modderman.  Made failing removal test
+    fatal.
 
  -- Petter Reinholdtsen <pere at debian.org>  Thu, 17 Jan 2008 11:00:21 +0100
 

Modified: trunk/src/insserv/debian/patches/00list
URL: http://svn.debian.org/wsvn/initscripts-ng/trunk/src/insserv/debian/patches/00list?rev=544&op=diff
==============================================================================
--- trunk/src/insserv/debian/patches/00list (original)
+++ trunk/src/insserv/debian/patches/00list Sat Jan 19 13:44:12 2008
@@ -12,3 +12,4 @@
 43_shutdown
 44_reportloopmemb
 45_loopsarefatal
+46_complete_removal

Added: trunk/src/insserv/debian/patches/46_complete_removal.dpatch
URL: http://svn.debian.org/wsvn/initscripts-ng/trunk/src/insserv/debian/patches/46_complete_removal.dpatch?rev=544&op=file
==============================================================================
--- trunk/src/insserv/debian/patches/46_complete_removal.dpatch (added)
+++ trunk/src/insserv/debian/patches/46_complete_removal.dpatch Sat Jan 19 13:44:12 2008
@@ -1,0 +1,43 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 46_complete_removal.dpatch by Petter Reinholdtsen
+
+Make sure symlink removal removes all symlinks, not just the ones in
+rulevels listed in default-start and default-stop.  Solves debian bug
+#460034.  Based on patch and feedback from Kel Modderman.
+
+ at DPATCH@
+diff -urNad insserv~/insserv.c insserv/insserv.c
+--- insserv~/insserv.c	2008-01-19 14:38:06.000000000 +0100
++++ insserv/insserv.c	2008-01-19 14:39:48.000000000 +0100
+@@ -1460,8 +1460,15 @@
+ 	    order = atoi(ptr);
+ 	    ptr += 2;
+ 
++/*
++ * Make sure removal removes all existing symlinks by disabling this
++ * for the non-SUSE case.  No idea if why this is needed for the SUSE
++ * case. [Petter Reinholdtsen 2008-01-19]
++ */
++#ifdef SUSE
+ 	    if (iargv && chkfor(ptr, iargv, icnt))
+ 		continue;		/* ignore scripts if removed later */
++#endif
+ 
+ 	    if (stat(d->d_name, &st_script) < 0) {
+ 		xremove(d->d_name);	/* dangling sym link */
+@@ -1491,6 +1498,15 @@
+ 		}
+ 		service = current_structure(token, order, runlevel, type);
+ 
++/*
++ * Break out here (and not above), as the rest of this loop is not
++ * used during removals.  [Petter Reinholdtsen 2008-01-19]
++ */
++#ifndef SUSE
++		if (iargv && chkfor(ptr, iargv, icnt))
++		    break;
++#endif /* not SUSE */
++
+ 		if (service->opts & SERV_KNOWN)
+ 		    continue;
+ 		service->opts |= (SERV_KNOWN|SERV_ENABLED);

Propchange: trunk/src/insserv/debian/patches/46_complete_removal.dpatch
------------------------------------------------------------------------------
    svn:executable = *

Modified: trunk/src/insserv/debian/run-testsuite
URL: http://svn.debian.org/wsvn/initscripts-ng/trunk/src/insserv/debian/run-testsuite?rev=544&op=diff
==============================================================================
--- trunk/src/insserv/debian/run-testsuite (original)
+++ trunk/src/insserv/debian/run-testsuite Sat Jan 19 13:44:12 2008
@@ -694,10 +694,10 @@
 
 list_rclinks
 
-${severity}_script_not_present 0 oldscript
-${severity}_script_present 1 oldscript
-${severity}_script_present 2 oldscript
-${severity}_script_not_present 3 oldscript
-${severity}_script_not_present 6 oldscript
+check_script_not_present 0 oldscript
+check_script_present 1 oldscript
+check_script_present 2 oldscript
+check_script_not_present 3 oldscript
+check_script_not_present 6 oldscript
 
 finish_test




More information about the Initscripts-ng-commits mailing list