aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorErik Troan <ewt@redhat.com>1998-04-05 15:31:10 +0000
committerErik Troan <ewt@redhat.com>1998-04-05 15:31:10 +0000
commitf9d8ca8195162004f1edda812e16121a8089f690 (patch)
treeea69cb36a48a94392c30595bd267fbedb77854a9
parentfa5a2db2ce9ad6ef64d25d5e7370f94dbedffda1 (diff)
downloadinitscripts-f9d8ca8195162004f1edda812e16121a8089f690.tar
initscripts-f9d8ca8195162004f1edda812e16121a8089f690.tar.gz
initscripts-f9d8ca8195162004f1edda812e16121a8089f690.tar.bz2
initscripts-f9d8ca8195162004f1edda812e16121a8089f690.tar.xz
initscripts-f9d8ca8195162004f1edda812e16121a8089f690.zip
fixed bugs in kernel-release handling
-rw-r--r--initscripts.spec6
-rwxr-xr-xrc.d/rc.sysinit8
2 files changed, 9 insertions, 5 deletions
diff --git a/initscripts.spec b/initscripts.spec
index 3c86cf76..8f50eb61 100644
--- a/initscripts.spec
+++ b/initscripts.spec
@@ -1,6 +1,6 @@
Summary: inittab and /etc/rc.d scripts
Name: initscripts
-%define version 3.51
+%define version 3.52
Version: %{version}
Copyright: GPL
Group: Base
@@ -17,6 +17,10 @@ that activate and deactivate most network interfaces.
%changelog
+* Sun Apr 05 1998 Erik Troan <ewt@redhat.com>
+
+- updated rc.sysinit to deal with kernel versions with release numbers
+
* Sun Mar 22 1998 Erik Troan <ewt@redhat.com>
- use ipcalc to calculate the netmask if one isn't specified
diff --git a/rc.d/rc.sysinit b/rc.d/rc.sysinit
index cef3a542..955d271d 100755
--- a/rc.d/rc.sysinit
+++ b/rc.d/rc.sysinit
@@ -115,17 +115,17 @@ else
USEMODULES=
fi
-# Get the modules ready to go
+# Get the modules ready to go -- we use awk here as cut is in /usr/bin
rm -f /lib/modules/default
if [ -n $USEMODULES ]; then
set `cat /proc/cmdline`
while [ $# -gt 0 ]; do
if echo $1 | grep '^BOOT_IMAGE=' > /dev/null ; then
- image=`echo $1 | cut -d= -f2`
+ image=`echo $1 | awk -F= '{ print $2 }'`
kernelfile=`/sbin/lilo -I $image`
if [ -n "$kernelfile" ]; then
- kernelname=`echo $kernelfile | cut -f1 -d-`
- versioninfo=`echo $kernelfile | cut -f2- -d-`
+ kernelname=`echo $kernelfile | awk -F- '{ print $1 }'`
+ versioninfo=`echo $kernelfile | awk -F- '{ print $2 }'`
if [ $kernelname = "/boot/vmlinuz" -a \
-d /lib/modules/$versioninfo -a \
$versioninfo != `uname -r` ]; then