]> TLD Linux GIT Repositories - rc-scripts.git/blobdiff - lib/functions
- PLD merge: don't delete base pidfile if other pid file was specified
[rc-scripts.git] / lib / functions
index 25803f6557872a00e4f4d30de2f2228a28760150..b4c4840aa6dce182ea5b226d74cb07eb01cdb94a 100644 (file)
@@ -896,7 +896,11 @@ killproc() {
 
        # Remove pid file if any.
        if [ "$notset" = "1" ]; then
-               rm -f /var/run/${base}.pid
+               if [ -f "${pidfile}" ] ; then
+                       rm -f "$pidfile"
+               else
+                       rm -f /var/run/${base}.pid
+               fi
        fi
 
        return $result