From 23037557033cf06b8df2247d2913aedc1ce4b032 Mon Sep 17 00:00:00 2001 From: andig Date: Fri, 1 Jun 2018 22:28:54 +0200 Subject: [PATCH] Avoid duplicate output buffer leaking memory --- Bridges/HttpKernel.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Bridges/HttpKernel.php b/Bridges/HttpKernel.php index d725210..1bd0b88 100644 --- a/Bridges/HttpKernel.php +++ b/Bridges/HttpKernel.php @@ -104,7 +104,7 @@ public function handle(ServerRequestInterface $request) if ($this->application instanceof TerminableInterface) { $this->application->terminate($syRequest, $syResponse); } - + if ($this->application instanceof Kernel) { $this->application->terminate($syRequest, $syResponse); } @@ -291,7 +291,6 @@ protected function mapResponse(SymfonyResponse $syResponse, $stdout='') $content = @ob_get_clean(); } else { - ob_start(); $content = $syResponse->getContent(); @ob_end_flush(); }