mirror of
https://github.com/M66B/NetGuard.git
synced 2025-01-01 12:54:07 +00:00
Limit sessions to 70% of maximum
This commit is contained in:
parent
078c2319fa
commit
643189728e
1 changed files with 1 additions and 1 deletions
|
@ -64,7 +64,7 @@ void *handle_events(void *a) {
|
|||
if (getrlimit(RLIMIT_NOFILE, &rlim))
|
||||
log_android(ANDROID_LOG_WARN, "getrlimit error %d: %s", errno, strerror(errno));
|
||||
else {
|
||||
maxsessions = (int) (rlim.rlim_cur * 75 / 100);
|
||||
maxsessions = (int) (rlim.rlim_cur * 70 / 100);
|
||||
log_android(ANDROID_LOG_WARN, "getrlimit soft %d hard %d max sessions %d",
|
||||
rlim.rlim_cur, rlim.rlim_max, maxsessions);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue