Fix run_server_preference() with no default protocol#2155
Merged
drwetter merged 1 commit intotestssl:3.0from Apr 24, 2022
Merged
Fix run_server_preference() with no default protocol#2155drwetter merged 1 commit intotestssl:3.0from
drwetter merged 1 commit intotestssl:3.0from
Conversation
run_server_preference() calls "default_proto=$(get_protocol $TMPFILE)" even if all attempts to connect to the server failed. This will result in default_proto incorrectly being set to TLS 1.2. This commit fixes the issue by only calling get_protocol() if an attempt to connect to the server was successful.
Collaborator
|
Good catch! Thanks. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
run_server_preference()callsdefault_proto=$(get_protocol $TMPFILE)even if all attempts to connect to the server failed. This will result indefault_protoincorrectly being set to TLS 1.2. This PR fixes the issue by only callingget_protocol()if an attempt to connect to the server was successful.