diff options
author | Nick Mathewson <nickm@torproject.org> | 2018-01-17 09:07:50 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2018-01-17 09:07:50 -0500 |
commit | 60dfdd9b154ed694a1eee202393b5eb6f664c03d (patch) | |
tree | 4b045b9429cafd28d46b29cf276c494247e054fc | |
parent | 5970836af8868fc3460b04d278169929241ab243 (diff) | |
parent | 0bfd5a659777688798722a20f894797a4f4b54f0 (diff) | |
download | tor-60dfdd9b154ed694a1eee202393b5eb6f664c03d.tar.gz tor-60dfdd9b154ed694a1eee202393b5eb6f664c03d.zip |
Merge branch 'bug21074_029'
-rw-r--r-- | src/common/compat.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/common/compat.c b/src/common/compat.c index 7c9b2f808e..6a61c6c919 100644 --- a/src/common/compat.c +++ b/src/common/compat.c @@ -1747,7 +1747,7 @@ set_max_file_descriptors(rlim_t limit, int *max_out) if (errno == EINVAL && try_limit < (uint64_t) rlim.rlim_cur) { /* On some platforms, OPEN_MAX is the real limit, and getrlimit() is * full of nasty lies. I'm looking at you, OSX 10.5.... */ - rlim.rlim_cur = MIN(try_limit, rlim.rlim_cur); + rlim.rlim_cur = MIN((rlim_t) try_limit, rlim.rlim_cur); if (setrlimit(RLIMIT_NOFILE, &rlim) == 0) { if (rlim.rlim_cur < (rlim_t)limit) { log_warn(LD_CONFIG, "We are limited to %lu file descriptors by " |