plugins: pidfile: reduce log noise

With the new practise of keeping record of process pid files, we no
longer need to log/update when reading back the same PID we already
have on file.

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
Joachim Wiberg
2021-03-12 00:35:13 +01:00
parent 8aba63a9e3
commit cfb3a9f2b9
+5 -3
View File
@@ -91,9 +91,11 @@ static void pidfile_update_conds(char *dir, char *name, uint32_t mask)
pid_t pid;
pid = pid_file_read(pid_file(svc));
_d("Forking service %s changed PID from %d to %d",
svc->cmd, svc->pid, pid);
svc->pid = pid;
if (pid != svc->pid) {
_d("Forking service %s changed PID from %d to %d",
svc->cmd, svc->pid, pid);
svc->pid = pid;
}
}
cond_set(cond);