diff options
author | Amitay Isaacs <amitay@gmail.com> | 2013-03-13 11:46:18 +1100 |
---|---|---|
committer | Amitay Isaacs <amitay@gmail.com> | 2013-03-25 17:41:37 +1100 |
commit | 7f88fe3d054817598fa0426b6d5b76cc260f8688 (patch) | |
tree | 5748c8ff107989af7b10f6c08773bac13bcf8a38 | |
parent | 257af5b62aeb5b2829b0cc1a11f5baf01677f471 (diff) | |
download | samba-7f88fe3d054817598fa0426b6d5b76cc260f8688.tar.gz samba-7f88fe3d054817598fa0426b6d5b76cc260f8688.tar.xz samba-7f88fe3d054817598fa0426b6d5b76cc260f8688.zip |
logging: Do not ignore stdout/stderr from the exec'd children
To log debugging information from child processes that are started
with vfork and exec, do not set close_on_exec on STDOUT and STDERR for
that process.
Signed-off-by: Amitay Isaacs <amitay@gmail.com>
(This used to be ctdb commit 08c53ee609b80f87450a7a1d7dd24fbcdf5ab7bc)
-rw-r--r-- | ctdb/server/ctdb_logging.c | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/ctdb/server/ctdb_logging.c b/ctdb/server/ctdb_logging.c index 7cf8b9f755..dfb50639aa 100644 --- a/ctdb/server/ctdb_logging.c +++ b/ctdb/server/ctdb_logging.c @@ -538,11 +538,6 @@ int ctdb_set_child_logging(struct ctdb_context *ctdb) close(old_stdout); close(old_stderr); - /* Is this correct for STDOUT and STDERR ? */ - set_close_on_exec(STDOUT_FILENO); - set_close_on_exec(STDERR_FILENO); - set_close_on_exec(p[0]); - fde = event_add_fd(ctdb->ev, ctdb->log, p[0], EVENT_FD_READ, ctdb_log_handler, ctdb->log); tevent_fd_set_auto_close(fde); |