mirror of
https://github.com/xcat2/confluent.git
synced 2025-01-28 03:48:35 +00:00
Have sockapi stay alive through as-yet uncaught circumstances
Previously, the client would be left hanging. Correct that by keeping the session alive and notifying the client of the unexpected condition.
This commit is contained in:
parent
3e1f90882f
commit
7caa9f741f
@ -71,7 +71,14 @@ def sessionhdl(connection, authname):
|
||||
tlvdata.send_tlvdata(connection, {'authpassed': 1})
|
||||
request = tlvdata.recv_tlvdata(connection)
|
||||
while request is not None:
|
||||
process_request(connection, request, cfm, authdata)
|
||||
try:
|
||||
process_request(connection, request, cfm, authdata)
|
||||
except:
|
||||
import traceback
|
||||
traceback.print_exc()
|
||||
tlvdata.send_tlvdata(connection, {'errorcode': 500,
|
||||
'error': 'Unexpected error'})
|
||||
tlvdata.send_tlvdata(connection, {'_requestdone': 1})
|
||||
request = tlvdata.recv_tlvdata(connection)
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user