dontkill: ignore errors
This commit is contained in:
parent
9403363364
commit
3c74700c7a
1 changed files with 6 additions and 3 deletions
|
@ -6,6 +6,9 @@ if (! ~ $#* 1) {
|
|||
exit usage
|
||||
}
|
||||
# see /sys/src/9/port/proc.c:/^killbig
|
||||
pids=`{psu | awk '$NF ~ /'$1'/ {print $2}'}
|
||||
~ $#pids 0 || {for(p in /proc/^$pids^/ctl){chmod +w $p; echo noswap >$p; chmod -w $p}} >/dev/null >[2=1]
|
||||
|
||||
psu | awk '$NF ~ /'$1'/ {
|
||||
c="/proc/"$2"/ctl"
|
||||
print "chmod +w "c
|
||||
print "echo noswap >"c
|
||||
print "chmod -w "c
|
||||
}' | rc >/dev/null >[2=1]
|
||||
|
|
Loading…
Reference in a new issue