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

address new clippy lint assigning-clones #2205

Merged
merged 2 commits into from
May 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion crates/proto/src/serialize/txt/zone.rs
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ impl<'a> Parser<'a> {

// @ is a placeholder for specifying the current origin
Token::At => {
current_name = origin.clone(); // TODO a COW or RC would reduce copies...
current_name.clone_from(&origin); // TODO a COW or RC would reduce copies...
State::TtlClassType
}

Expand Down
4 changes: 2 additions & 2 deletions crates/resolver/src/name_server/name_server_pool.rs
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ where
#[cfg(feature = "dns-over-rustls")]
let ns_config = {
let mut ns_config = ns_config.clone();
ns_config.tls_config = config.client_config().clone();
ns_config.tls_config.clone_from(config.client_config());
ns_config
};
#[cfg(not(feature = "dns-over-rustls"))]
Expand All @@ -97,7 +97,7 @@ where
#[cfg(feature = "dns-over-rustls")]
let ns_config = {
let mut ns_config = ns_config.clone();
ns_config.tls_config = config.client_config().clone();
ns_config.tls_config.clone_from(config.client_config());
ns_config
};
#[cfg(not(feature = "dns-over-rustls"))]
Expand Down