]> git.pld-linux.org Git - projects/rc-scripts.git/commitdiff
killproc(): fill base and pid variables based on waitname.
authorArkadiusz Miśkiewicz <arekm@maven.pl>
Sat, 30 Apr 2005 20:53:33 +0000 (20:53 +0000)
committerArkadiusz Miśkiewicz <arekm@maven.pl>
Sat, 30 Apr 2005 20:53:33 +0000 (20:53 +0000)
svn-id: @5896

rc.d/init.d/functions

index 9f238fa9ad56a963b6cb20c111b45e39f6c992c2..8afd303c90b4286db847388d786a2e8f6dcf0031 100644 (file)
@@ -617,6 +617,11 @@ killproc()
        fi
        
        if [ -n "$waitname" -a -n "$waittime" ]; then
+               # Save basename.
+               base=$(basename "$waitname")
+               # Find pid.
+               pid=$(pidofproc "$waitname" "$pidfile")
+               [ -z "$pid" ] && pid=$(pidofproc "$base" "$pidfile")
                i=0
                while [ "$i" -lt "$waittime" ]; do
                        i=$(( i + 1 ))
This page took 0.108616 seconds and 4 git commands to generate.