소스 검색

Added an optimisation for PHP-FPM (FastCGI Process Manager).
As soon as a full Response is dispatched to the browser, the HTTP connection is closed, but the script stays alive on FPM servers.

Lee McDermott 14 년 전
부모
커밋
7e89a6ad41
1개의 변경된 파일4개의 추가작업 그리고 0개의 파일을 삭제
  1. 4 0
      src/Symfony/Component/HttpFoundation/Response.php

+ 4 - 0
src/Symfony/Component/HttpFoundation/Response.php

@@ -153,6 +153,10 @@ class Response
     {
         $this->sendHeaders();
         $this->sendContent();
+        
+        if (function_exists('fastcgi_finish_request')) {
+            fastcgi_finish_request();
+        }
     }
 
     /**