[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#178944: discover: Fix still needed for sarge.

Package: discover
Version: 1.1-6
Followup-For: Bug #178944

I'm reporting this from a woody system but I have just looked on a
testing(sarge) system and /etc/init.d/discover contains 2 instances of
the "cut" command.

"cut" in sarge is still in /usr/bin/ 

The first instance (in discover_1.5-2_i386.deb) is:
ARGUMENTS=$(sed "s/#.*$//" $CONFFILE | grep "^boot " | cut -c6-)

This could be replaced by something like:
ARGUMENTS=$(sed "s/#.*$//" $CONFFILE | grep "^boot " | sed -e's/^.....//')

The second instance is:
if cut -d" " -f1 /proc/modules | grep -q "^${module}\$" ; then

This could be replaced by something like:
if cat /proc/modules |(while read col1 junk ; do echo $col1)|grep -q "^${module}\$" ; then
if cat /proc/modules | sed -e's/ [:digit:]* .*//' |grep -q "^${module}\$" ; then

"sed" lives in /bin/ so should be OK!

I hope this helps!
Alex Owen

-- System Information
Debian Release: 3.0
Architecture: i386
Kernel: Linux pc-nt556.cc.le.ac.uk 2.4.18-686 #1 Sun Apr 14 11:32:47 EST 2002 i686

Versions of packages discover depends on:
ii  ash                           0.3.8-37   NetBSD /bin/sh
ii  libc6                         2.2.5-11.5 GNU C Library: Shared libraries an
ii  libdiscover1                  1.1-6      hardware identification library

Reply to: