From 823288dd0b78535f3f9e9fb533fc982656e346bb Mon Sep 17 00:00:00 2001 From: Julien Duponchelle Date: Thu, 1 Jun 2017 18:35:03 +0200 Subject: [PATCH] Fix a crash in some cases --- gns3server/web/response.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gns3server/web/response.py b/gns3server/web/response.py index c394d305..13c97742 100644 --- a/gns3server/web/response.py +++ b/gns3server/web/response.py @@ -46,7 +46,8 @@ class Response(aiohttp.web.Response): def enable_chunked_encoding(self): # Very important: do not send a content length otherwise QT closes the connection (curl can consume the feed) - self.content_length = None + if self.content_length: + self.content_length = None super().enable_chunked_encoding() @asyncio.coroutine