8 name="pgrep -LF <pidfile>"
9 pidfile=`mktemp /tmp/$base.XXXXXX` || exit 1
10 sleep=`mktemp /tmp/$base.XXXXXX` || exit 1
11 ln -sf /bin/sleep $sleep
12 daemon -p $pidfile $sleep 5
15 pid=`pgrep -f -L -F $pidfile $sleep`
16 if [ "$pid" = "$chpid" ]; then
19 echo "not ok 1 - $name"
23 # Be sure we cannot find process which pidfile is not locked.
27 echo $chpid > $pidfile
28 pgrep -f -L -F $pidfile $sleep 2>/dev/null
32 echo "not ok 2 - $name"