slitaz-boot-scripts rev 147 2.8
rc.functions/active_pidfile: filter pid
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Tue Mar 10 17:38:08 2009 +0000 (2009-03-10) |
parents | 979868f40866 |
children | 9b4be5039c9f |
files | etc/init.d/rc.functions |
line diff
1.1 --- a/etc/init.d/rc.functions Mon Mar 09 20:04:05 2009 +0000 1.2 +++ b/etc/init.d/rc.functions Tue Mar 10 17:38:08 2009 +0000 1.3 @@ -31,7 +31,8 @@ 1.4 { 1.5 if [ ! -e $1 ]; then 1.6 return 1 1.7 - elif grep -qs "Name:.$(basename $2)$" /proc/$(cat $1)/status ; then 1.8 + elif grep -qs "Name:.$(basename $2)$" \ 1.9 + /proc/$(cat $1 | sed 's/[^0-9]//g')/status ; then 1.10 return 0 1.11 else 1.12 rm -f $1