From 313535c5996e59dfa371814ba8d96ad068ec9b33 Mon Sep 17 00:00:00 2001 From: 38elements Date: Thu, 9 Mar 2017 13:36:01 +0900 Subject: [PATCH] Fix bail_out() --- sanic/server.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sanic/server.py b/sanic/server.py index 0c4bb4b8..39816e28 100644 --- a/sanic/server.py +++ b/sanic/server.py @@ -254,7 +254,7 @@ class HttpProtocol(asyncio.Protocol): self.transport.close() def bail_out(self, message, from_error=False): - if from_error and self.transport.is_closing(): + if from_error or self.transport.is_closing(): log.error( ("Transport closed @ {} and exception " "experienced during error handling").format(