Package: blktrace
Version: 1.0.1-2.1
Severity: minor
Tags: patch

If a system has a debugfs mounted somewhere other than /sys/kernel/debug
(perhaps a legacy entry), the initscript doesn't cater for finding
multiple entries when stopping or checking the status.

On stop:
/etc/init.d/mountdebugfs: line 87: [: /debug: unary operator expected

On "status":
/etc/init.d/mountdebugfs: line 108: [: /debug: unary operator expected

To reproduce: add this to /etc/fstab, or mount it by hand
none            /debug                  debugfs defaults        0       0

-- System Information:
Debian Release: 7.0
  APT prefers testing
  APT policy: (800, 'testing'), (3, 'unstable')
Architecture: i386 (x86_64)

Kernel: Linux 3.2.0-4-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages blktrace depends on:
ii  libaio1   0.3.109-3
ii  libc6     2.13-38
ii  lsb-base  4.1+Debian8
ii  python    2.7.3-4

blktrace recommends no packages.

Versions of packages blktrace suggests:
ii  gnuplot-x11  4.6.0-8
--- /etc/init.d/mountdebugfs.orig	2008-02-22 12:33:56.000000000 +0000
+++ /etc/init.d/mountdebugfs	2013-04-12 09:42:45.000000000 +0100
@@ -84,7 +84,7 @@
 
 umount_debugfs ()
 {
-	if  [ $mountpoints ]
+	if  [ "$mountpoints" ]
 	then
 		for d in $mountpoints
 		do
@@ -105,7 +105,7 @@
 
 show_status ()
 {
-	if  [ $mountpoints ]
+	if  [ "$mountpoints" ]
 	then
 		for d in $mountpoints
 		do

Reply via email to