Changeset 12363
- Timestamp:
- Apr 16, 2011, 10:33:29 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/libtransmission/fdlimit.c
r12229 r12363 747 747 tr_fdSetFileLimit( tr_session * session, int limit ) 748 748 { 749 int max; 750 751 /* This is a vaguely arbitrary number. 752 It takes announcer.c's MAX_CONCURRENT_TASKS into account, 753 plus extra positions for the listening sockets, 754 plus a few more just to be safe */ 755 const int buffer_slots = 128; 756 749 757 ensureSessionFdInfoExists( session ); 758 759 max = __FD_SETSIZE - session->fdInfo->socket_limit - buffer_slots; 760 if( limit > max ) 761 limit = max; 750 762 751 763 if( limit != tr_fdGetFileLimit( session ) )
Note: See TracChangeset
for help on using the changeset viewer.