mirror of
https://github.com/EasyTier/EasyTier.git
synced 2026-05-07 10:14:35 +00:00
clippy all codes (#1214)
1. clippy code 2. add fmt and clippy check in ci
This commit is contained in:
@@ -172,7 +172,7 @@ impl NatDstConnector for NatDstQUICConnector {
|
||||
_ipv4: &Ipv4Packet,
|
||||
_real_dst_ip: &mut Ipv4Addr,
|
||||
) -> bool {
|
||||
return hdr.from_peer_id == hdr.to_peer_id && !hdr.is_kcp_src_modified();
|
||||
hdr.from_peer_id == hdr.to_peer_id && !hdr.is_kcp_src_modified()
|
||||
}
|
||||
|
||||
fn transport_type(&self) -> TcpProxyEntryTransportType {
|
||||
@@ -457,7 +457,7 @@ impl TcpProxyRpc for QUICProxyDstRpcService {
|
||||
let mut reply = ListTcpProxyEntryResponse::default();
|
||||
if let Some(tcp_proxy) = self.0.upgrade() {
|
||||
for item in tcp_proxy.iter() {
|
||||
reply.entries.push(item.value().clone());
|
||||
reply.entries.push(*item.value());
|
||||
}
|
||||
}
|
||||
Ok(reply)
|
||||
|
||||
Reference in New Issue
Block a user