mirror of
https://github.com/GNS3/gns3-server
synced 2024-12-25 16:28:11 +00:00
Force close the keep alive when sending a 401
Work around a Qt issue where Qt timeout instead of handling the 401 this happen only for the first query send by the client.
This commit is contained in:
parent
958274e8f6
commit
802d0628bd
@ -109,6 +109,9 @@ class Route(object):
|
|||||||
response = Response(request=request, route=route)
|
response = Response(request=request, route=route)
|
||||||
response.set_status(401)
|
response.set_status(401)
|
||||||
response.headers["WWW-Authenticate"] = 'Basic realm="GNS3 server"'
|
response.headers["WWW-Authenticate"] = 'Basic realm="GNS3 server"'
|
||||||
|
# Force close the keep alive. Work around a Qt issue where Qt timeout instead of handling the 401
|
||||||
|
# this happen only for the first query send by the client.
|
||||||
|
response.force_close()
|
||||||
return response
|
return response
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
|
Loading…
Reference in New Issue
Block a user