Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(manager): use TcpListener to check free port #1240

Closed
wants to merge 8 commits into from

Conversation

RolandSherwin
Copy link
Member

@RolandSherwin RolandSherwin commented Jan 29, 2024

Description

Summary generated by Reviewpad on 29 Jan 24 14:36 UTC

This pull request updates the sn_node_manager module by using TcpListener instead of SocketBinder in the service.rs file. It also includes some changes to the Cargo.toml file.

@reviewpad reviewpad bot requested a review from jacderida January 29, 2024 14:36
@reviewpad reviewpad bot added Small Pull request is small waiting-for-review labels Jan 29, 2024
@@ -154,12 +148,9 @@
}

fn is_port_free(&self, port: u16) -> bool {
let socket = SocketBinder::bind(("127.0.0.1", port));
let socket = TcpListener::bind(("127.0.0.1", port));

Check notice

Code scanning / devskim

Accessing localhost could indicate debug code, or could hinder scaling. Note

Do not leave debug code in production
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Small Pull request is small
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant