slapd does not remove pid file on exit (ITS#2318)

Full_Name: Torsten Landschoff
Version: CVS as of Wed, 19 Feb 2003 04:08:20 +0100
OS: Debian unstable
URL: http://people.debian.org/~torsten/openldap2.1/torsten-030219.diff
Submission from: (NULL) (217.227.203.154)
slapd creates a PID file when using the pidfile option in slapd.conf. That file
is not removed
on termination though which can become a problem if you are using SE Linux (as
long as the pid file is there you can't start a new server, and only the server
can delete it...).
Attached is a patch that makes sense for me, I hope it does for you too ;-)
For reference: The Debian bug report is at http://bugs.debian.org/162284.
Greetings
Torsten