diff options
author | Steven Murdoch <Steven.Murdoch@cl.cam.ac.uk> | 2010-12-01 15:38:18 +0000 |
---|---|---|
committer | Steven Murdoch <Steven.Murdoch@cl.cam.ac.uk> | 2010-12-01 15:38:18 +0000 |
commit | 786abbd54c77d4d39488e27ddde0b26ee5c9478f (patch) | |
tree | bcf854d968540bc4149810e85beb85e5afba7ebe | |
parent | f04d7e6009e0ac739de62aed94b52d5361fae927 (diff) | |
download | tor-786abbd54c77d4d39488e27ddde0b26ee5c9478f.tar.gz tor-786abbd54c77d4d39488e27ddde0b26ee5c9478f.zip |
Open log files with CLOEXEC flag set
-rw-r--r-- | src/common/log.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/common/log.c b/src/common/log.c index e507275830..6f86406c2c 100644 --- a/src/common/log.c +++ b/src/common/log.c @@ -686,7 +686,7 @@ add_file_log(const log_severity_list_t *severity, const char *filename) int fd; logfile_t *lf; - fd = open(filename, O_WRONLY|O_CREAT|O_APPEND, 0644); + fd = tor_open_cloexec(filename, O_WRONLY|O_CREAT|O_APPEND, 0644); if (fd<0) return -1; if (tor_fd_seekend(fd)<0) |