chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
19686d3
)
process-util: use raw_getpid() in getpid_cache() internally (#8115)
author
Lennart Poettering
<lennart@poettering.net>
Wed, 7 Feb 2018 02:10:09 +0000
(
03:10
+0100)
committer
Sven Eden
<yamakuzure@gmx.net>
Wed, 30 May 2018 05:58:49 +0000
(07:58 +0200)
We have the raw_getpid() definition in place anyway, and it's certainly
beneficial to expose the same semantics on pre glibc 2.24 and after it
too, hence always bypass glibc for this, and always cache things on our
side.
Fixes: #8113
src/basic/process-util.c
patch
|
blob
|
history
diff --git
a/src/basic/process-util.c
b/src/basic/process-util.c
index ccf828389c2f07f6908db8778a91db0758edbc29..ba8b3d80f64bc8378945368f7d35ef5c49d51d58 100644
(file)
--- a/
src/basic/process-util.c
+++ b/
src/basic/process-util.c
@@
-813,13
+813,6
@@
void sigkill_waitp(pid_t *pid) {
sigkill_wait(*pid);
}
-void sigterm_wait(pid_t pid) {
- assert(pid > 1);
-
- if (kill_and_sigcont(pid, SIGTERM) > 0)
- (void) wait_for_terminate(pid, NULL);
-}
-
int kill_and_sigcont(pid_t pid, int sig) {
int r;