aboutsummaryrefslogtreecommitdiff
path: root/src/common/compat.c
diff options
context:
space:
mode:
authorSteven Murdoch <Steven.Murdoch@cl.cam.ac.uk>2010-11-20 13:50:55 +0000
committerSteven Murdoch <Steven.Murdoch@cl.cam.ac.uk>2010-11-20 13:50:55 +0000
commit9d63dfcf49924fad573109c80dfa881c19cfe195 (patch)
tree33f3021a6eb216e6fac76ee124827eee70d056d0 /src/common/compat.c
parentb4f56dd4c6483933d06b382ab4e4a956b238f783 (diff)
downloadtor-9d63dfcf49924fad573109c80dfa881c19cfe195.tar
tor-9d63dfcf49924fad573109c80dfa881c19cfe195.tar.gz
Fix compile error on MacOS X (and other platforms without O_CLOEXEC)
Diffstat (limited to 'src/common/compat.c')
-rw-r--r--src/common/compat.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/common/compat.c b/src/common/compat.c
index 42602fb3a..07d961812 100644
--- a/src/common/compat.c
+++ b/src/common/compat.c
@@ -112,7 +112,7 @@ tor_open_cloexec(const char *path, int flags, unsigned mode)
int fd = open(path, flags, mode);
#ifdef FD_CLOEXEC
if (fd >= 0)
- fcntl(s, F_SETFD, FD_CLOEXEC);
+ fcntl(fd, F_SETFD, FD_CLOEXEC);
#endif
return fd;
#endif