From 06cfd408fc92b0b879a5fb1fd62f762ddb62bff6 Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Tue, 24 Aug 2021 07:56:49 -0400 Subject: [PATCH] Fix handling of abrupt client close --- confluent_server/confluent/sockapi.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/confluent_server/confluent/sockapi.py b/confluent_server/confluent/sockapi.py index bb100fc4..4172313c 100644 --- a/confluent_server/confluent/sockapi.py +++ b/confluent_server/confluent/sockapi.py @@ -200,7 +200,10 @@ def sessionhdl(connection, authname, skipauth=False, cert=None): send_data(connection, {'errorcode': 500, 'error': 'Unexpected error - ' + str(e)}) send_data(connection, {'_requestdone': 1}) - request = tlvdata.recv(connection) + try: + request = tlvdata.recv(connection) + except Exception: + request = None finally: cfm.close_client_files() try: