(In reply to Jean Delvare from comment #11) Hmmm ... should checkproc simply ignore if it is not able to detect the session leader of a process? If I check a running /usr/bin/gpg-agent all went OK strace -e getsid checkproc -p 19315 /usr/bin/gpg-agent getsid(19315) = 19315 +++ exited with 0 +++ onyl if the process is gone the warning occurs. The only idea I have is to check if the process its self exists and if not to skip the session test.