Validate the open file limit when creating a socket

Fixes #16288

Signed-off-by: David Goulet <dgoulet@ev0ke.net>
This commit is contained in:
David Goulet
2015-06-03 13:56:01 -04:00
committed by Nick Mathewson
parent 64bdf040f0
commit 699acd8d54
4 changed files with 69 additions and 27 deletions
+6
View File
@@ -0,0 +1,6 @@
o Major bugfixes (open file limit):
- The max open file limit wasn't checked before calling
tor_accept_socket_nonblocking() which made tor go beyond the open
file limit set previously. With this fix, before opening a new socket,
tor validates the open file limit just before and if the max has been
reached, return EMFILE.; Fixes #16288; bugfix on tor-0.1.1.1-alpha~74.