소스 검색

* Decrease bogus FD if they successfully close

svn: 1911
Bryan Drewery 21 년 전
부모
커밋
0d809ddeec
1개의 변경된 파일2개의 추가작업 그리고 0개의 파일을 삭제
  1. 2 0
      src/shell.c

+ 2 - 0
src/shell.c

@@ -127,6 +127,8 @@ void check_maxfiles()
       if (!findanysnum(i))
         if ((close(i)) == -1)			/* try to close the BOGUS fd (likely a KQUEUE) */
           failed_close++;
+        else
+          bogus--;
     if (bogus >= 150 || failed_close >= 50) {
       nuke_server("Max FD reached, restarting...");
       cycle_time = 0;