1 diff --git a/lib/functions b/lib/functions
2 index 8d018f7..501cac9 100644
5 @@ -1009,7 +1009,7 @@ pidofproc() {
8 # Next try "pidof" if pidfile is not specified
9 - if [ -z "$pid" ] && [ -z "$pidfile" ]; then
10 + if [ -z "$pid" ] && [ -z "$2" ]; then
11 pid=$(pidof -o $$ -o $PPID -o %PPID -x "$1")