Skip to content

[27.x backport] cli/connhelper: getConnectionHelper: move ssh-option funcs out of closure - #5392

Merged
thaJeztah merged 1 commit into
docker:27.xfrom
vvoland:5345-27.x
Sep 2, 2024
Merged

[27.x backport] cli/connhelper: getConnectionHelper: move ssh-option funcs out of closure#5392
thaJeztah merged 1 commit into
docker:27.xfrom
vvoland:5345-27.x

Conversation

@vvoland

Copy link
Copy Markdown
Collaborator

The addSSHTimeout and disablePseudoTerminalAllocation were added in commits a5ebe22 and f3c2c26, and called inside the Dialer function, which means they're called every time the Dialer is called. Given that the sshFlags slice is not mutated by the Dialer, we can call these functions once.

- A picture of a cute animal (not mandatory but encouraged)

…sure
The addSSHTimeout and disablePseudoTerminalAllocation were added in commits
a5ebe22 and f3c2c26,
and called inside the Dialer function, which means they're called every
time the Dialer is called. Given that the sshFlags slice is not mutated
by the Dialer, we can call these functions once.
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 0fd3fb0)
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
@vvolandvvoland added status/2-code-review kind/refactor PR's that refactor, or clean-up code labels Sep 2, 2024
@vvolandvvoland added this to the 27.2.1 milestone Sep 2, 2024
@vvolandvvoland self-assigned this Sep 2, 2024
@codecov-commenter

codecov-commenter commented Sep 2, 2024

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 0% with 2 lines in your changes missing coverage. Please review.

Project coverage is 60.99%. Comparing base (83072c0) to head (1a0b6a7).
Report is 5 commits behind head on 27.x.

Additional details and impacted files
@@ Coverage Diff @@## 27.x #5392 +/- ##
=======================================
Coverage 60.99% 60.99% =======================================
Files 304 304 Lines 21357 21357 =======================================
Hits 13026 13026 Misses 7402 7402 Partials 929 929 

@thaJeztahthaJeztah left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@thaJeztah
thaJeztah merged commit 074dfc0 into docker:27.xSep 2, 2024
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/refactorPR's that refactor, or clean-up codestatus/2-code-review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@vvoland@codecov-commenter@thaJeztah