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:
db12315
)
socket: don't close sockets when activating per-connection units
author
Lennart Poettering
<lennart@poettering.net>
Wed, 14 Jul 2010 02:47:57 +0000
(
04:47
+0200)
committer
Lennart Poettering
<lennart@poettering.net>
Wed, 14 Jul 2010 02:47:57 +0000
(
04:47
+0200)
src/execute.c
patch
|
blob
|
history
diff --git
a/src/execute.c
b/src/execute.c
index 6b6c2855b48739c04febe6878c37d6370f3e3b11..352def3cfaff28f8826a64c27a1c533471bbacfc 100644
(file)
--- a/
src/execute.c
+++ b/
src/execute.c
@@
-976,7
+976,8
@@
int exec_spawn(ExecCommand *command,
/* Close sockets very early to make sure we don't
* block init reexecution because it cannot bind its
* sockets */
- if (close_all_fds(fds, n_fds) < 0) {
+ if (close_all_fds(socket_fd >= 0 ? &socket_fd : fds,
+ socket_fd >= 0 ? 1 : n_fds) < 0) {
r = EXIT_FDS;
goto fail;
}