about summary refs log tree commit diff
path: root/debian
diff options
context:
space:
mode:
authorMichael Biebl <biebl@debian.org>2011-03-11 14:29:03 +0100
committerMichael Biebl <biebl@debian.org>2011-03-11 14:33:47 +0100
commitf2e3bcc5d4e6f22cd3d90def27c9c30dd3f45c7e (patch)
treeb85853982d80d05fe6b5f810c7d64e75f5d52296 /debian
parent0c0faae456276066354e4f05bf3060a80f0964fb (diff)
Properly quote physical interfaces in blacklist script
* debian/ifblacklist_migrate.sh
  - Only comment out iface lines if we have an exact match for the network
    interface. (Closes: #612247)
Diffstat (limited to 'debian')
-rw-r--r--debian/changelog3
-rw-r--r--debian/ifblacklist_migrate.sh4
2 files changed, 5 insertions, 2 deletions
diff --git a/debian/changelog b/debian/changelog
index 04226660..521e88b3 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -7,6 +7,9 @@ network-manager (0.8.1-6+squeeze1) UNRELEASED; urgency=low
     - Newer versions of dnsmasq validate the option parameters more strictly.
       Instead of passing a bogus file name simply use --conf-file without
       additional parameters. (Closes: #615082)
+  * debian/ifblacklist_migrate.sh
+    - Only comment out iface lines if we have an exact match for the network
+      interface. (Closes: #612247)
 
  -- Michael Biebl <biebl@debian.org>  Sat, 22 Jan 2011 16:53:48 +0100
 
diff --git a/debian/ifblacklist_migrate.sh b/debian/ifblacklist_migrate.sh
index 1d41266c..c30971c2 100644
--- a/debian/ifblacklist_migrate.sh
+++ b/debian/ifblacklist_migrate.sh
@@ -41,7 +41,7 @@ for i in $auto_ifs; do
       if test x$nulled_line != x; then
 	  line_count=$(expr $line_count + 1)
       fi
-  done  
+  done
 
   if test $line_count -eq 0 -a $word_count -gt 0; then
      ifaces_to_disable="$ifaces_to_disable $i"
@@ -59,7 +59,7 @@ if [ -n "$ifaces_to_disable" ]; then
     cp $NIF_FILE "$NIF_FILE.bak-${backup_suffix}"
     for i in $ifaces_to_disable; do
 	echo -n "Disabling interface: $i ... "
-	sed -i -e "s/^\([ \t]*iface.*$i.*\)$/#NetworkManager#\1/" $NIF_FILE
+	sed -i -e "s/^\([ \t]*iface.*[ \t]$i[ \t].*\)$/#NetworkManager#\1/" $NIF_FILE
 	echo done.
     done
 fi