Bug 54494 - various oversights in /etc/rc.d/init.d/functions
various oversights in /etc/rc.d/init.d/functions
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: initscripts (Show other bugs)
7.1
All Linux
medium Severity low
: ---
: ---
Assigned To: Bill Nottingham
Brock Organ
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2001-10-10 03:07 EDT by aSmig
Modified: 2014-03-16 22:23 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2002-01-24 23:41:46 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description aSmig 2001-10-10 03:07:48 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.3) Gecko/20010802

Description of problem:
Well, I spent about 20 minutes looking around for a public CVS that I could
submit these to but apparently my search skills need some tuning.  Anyhow,
I'm sure this isn't the proper method for submitting this sort of info but
I do want it to be useful to others rather than rotting on my drive.  There
are also a large number of unary operator errors generated by unquoted
variables in various init scripts.  Try booting a system with NETWORKING
undefined in /etc/sysconfig/network.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1.sed -ne '218,219p' /etc/rc.d/init.d/functions
	

Actual Results:                  read pid < /var/run/${base}.pid
                for p in $line ; do


Expected Results:                  read line < /var/run/${base}.pid
                for p in $line ; do

Additional info:

# diff /etc/rc.d/init.d/functions /usr/local/src/initscripts/functions
95c95,96
<                  base=${1#--user=}
---
>                  base=${1#--check=}
>                  gotbase="yes"
116c117
<         [ -z $gotbase ] && base=${1##*/}
---
>         [ -z "$gotbase" ] && base=${1##*/}
136c137
<       [ $? = 0 ] && success $"$base startup" || failure $"$base startup"
---
>       [ "$?" -eq 0 ] && success $"$base startup" || failure $"$base startup"
143c144
<       if [ $# = 0 ]; then
---
>       if [ "$#" -eq 0 ]; then
168,169c169,170
<                 [ $BOOTUP = "verbose" ] && echo -n "$base "
<               if [ "$notset" = "1" ] ; then
---
>                 [ "$BOOTUP" = "verbose" ] && echo -n "$base "
>               if [ "$notset" -eq "1" ] ; then
183c184
<                       [ $RC -eq 0 ] && failure $"$base shutdown" ||
success $"$base shutdown"
---
>                       [ "$RC" -eq 0 ] && failure $"$base shutdown" ||
success $"$base shutdown"
190c191
<                               [ $RC -eq 0 ] && success $"$base
$killlevel" || failure $"$base $killlevel"
---
>                               [ "$RC" -eq 0 ] && success $"$base
$killlevel" || failure $"$base $killlevel"
211c212
<       if [ $# = 0 ] ; then
---
>       if [ "$#" = 0 ] ; then
218c219
<               read pid < /var/run/${base}.pid
---
>               read line < /var/run/${base}.pid
234c235
<       if [ $# = 0 ] ; then
---
>       if [ "$#" = 0 ] ; then
262c263
<       if [ $# = 0 ] ; then
---
>       if [ "$#" = 0 ] ; then
Comment 1 Bill Nottingham 2002-01-24 23:46:21 EST
A couple of these were fixed in 7.2, more will be fixed in initscripts-6.51-1.

Note You need to log in before you can comment on or make changes to this bug.