1
0
mirror of https://github.com/anope/anope.git synced 2026-06-12 19:14:47 +02:00

Fix the pid check on systems with reliable pid ordering (e.g. Docker).

This commit is contained in:
Sadie Powell
2025-08-25 18:40:19 +01:00
parent 43f88524e2
commit 59c777d4ff
+1 -1
View File
@@ -241,7 +241,7 @@ static void write_pidfile()
{
pid_t oldpid = 0;
oldstream >> oldpid;
if (oldpid && kill(oldpid, 0) == 0)
if (oldpid && oldpid != getpid() && kill(oldpid, 0) == 0)
throw CoreException("Anope is already running with process id " + Anope::ToString(oldpid));
}
oldstream.close();