Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Step:15-SP6
pacemaker.14738
bsc#1131353-bsc#1131356-0001-Low-libcrmcommon-r...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File bsc#1131353-bsc#1131356-0001-Low-libcrmcommon-return-proper-code-if-testing-pid-i.patch of Package pacemaker.14738
From d9b0269d59a00329feb19b6e65b10a233a3dd414 Mon Sep 17 00:00:00 2001 From: Ken Gaillot <kgaillot@redhat.com> Date: Mon, 29 Apr 2019 14:34:32 -0500 Subject: [PATCH] Low: libcrmcommon: return proper code if testing pid is denied 7dda20d avoided a use-of-NULL in an unlikely corner case, but returned the wrong code in that case. --- lib/common/pid.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/common/pid.c b/lib/common/pid.c index 4fbf2dd26..ccee03fc1 100644 --- a/lib/common/pid.c +++ b/lib/common/pid.c @@ -47,7 +47,7 @@ crm_pid_active(long pid, const char *daemon) } else if ((rc = kill(pid, 0)) < 0 && errno == ESRCH) { return 0; /* no such PID detected */ - } else if (rc < 0 && have_proc_pid == -1) { + } else if (rc < 0 && (daemon == NULL || have_proc_pid == -1)) { if (last_asked_pid != pid) { crm_info("Cannot examine PID %ld: %s", pid, strerror(errno)); last_asked_pid = pid; -- 2.16.4
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor