Skip to content

Commit

Permalink
fix: cargo clippy
Browse files Browse the repository at this point in the history
Signed-off-by: sylvain-pierrot <[email protected]>
  • Loading branch information
sylvain-pierrot committed May 2, 2024
1 parent f2327b5 commit 1ba3135
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/vmm/src/core/devices/virtio/net/bridge.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ impl Bridge {
tokio::spawn(connection);

let br = Self { name, handle };
let _ = br.create_bridge_if_not_exist();
br.create_bridge_if_not_exist();

br
}
Expand Down
2 changes: 1 addition & 1 deletion src/vmm/src/core/devices/virtio/net/iptables.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use super::xx_netmask_width;

pub fn iptables_ip_masq(network: Ipv4Addr, netmask: Ipv4Addr) {
let prefix_len = xx_netmask_width(netmask.octets());
let source = format!("{}/{}", network.to_string(), prefix_len);
let source = format!("{}/{}", network, prefix_len);

let ipt = iptables::new(false).unwrap();
let rule = format!("-s {} ! -o br0 -j MASQUERADE", source);
Expand Down

0 comments on commit 1ba3135

Please sign in to comment.