Module Name: src
Committed By: otis
Date: Thu Sep 17 20:29:04 UTC 2020
Modified Files:
src/etc: rc.subr
Log Message:
Fix waiting for PIDs on stop.
Fix expansion of positional parameters. Also move the local
variable declaration to more apropriate place.
To generate a diff of this commit:
cvs rdiff -u -r1.104 -r1.105 src/etc/rc.subr
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/etc/rc.subr
diff -u src/etc/rc.subr:1.104 src/etc/rc.subr:1.105
--- src/etc/rc.subr:1.104 Sun Apr 5 21:03:08 2020
+++ src/etc/rc.subr Thu Sep 17 20:29:03 2020
@@ -1,4 +1,4 @@
-# $NetBSD: rc.subr,v 1.104 2020/04/05 21:03:08 christos Exp $
+# $NetBSD: rc.subr,v 1.105 2020/09/17 20:29:03 otis Exp $
#
# Copyright (c) 1997-2011 The NetBSD Foundation, Inc.
# All rights reserved.
@@ -322,7 +322,7 @@ kill_pids()
{
local signal=$1
shift
- local list="$@"
+ local list="$*"
local j=
local nlist=
for j in $list; do
@@ -343,14 +343,15 @@ wait_for_pids()
{
local ntries=0
local prefix=
- local list="$@"
+ local nlist=
+ local list="$*"
if [ -z "$list" ]; then
return
fi
while true; do
- local nlist=$(kill_pids 0 $list)
+ nlist=$(kill_pids 0 $list)
if [ -z "$nlist" ]; then
break
fi