Commit 4f29e2b3 authored by Andrey Gursky's avatar Andrey Gursky Committed by Philipp Hörist

Preserve SSL handshake errors order

Sets are unordered and list with push/pop acts as LIFO, though we need FIFO.
Since the number of elements is tiny, no need to use deque.

Addresses #9120
parent f13ff8ac
Pipeline #1464 passed with stages
in 2 minutes and 22 seconds
......@@ -1333,7 +1333,8 @@ class Connection(CommonConnection, ConnectionHandlers):
ssl_errors = con.Connection.ssl_errors
ignored_ssl_errors = self._get_ignored_ssl_errors()
self._ssl_errors = set(ssl_errors) - set(ignored_ssl_errors)
self._ssl_errors = [n for n in ssl_errors if n not in ignored_ssl_errors]
self._ssl_errors.reverse()
self.process_ssl_errors()
def _get_ignored_ssl_errors(self):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment