Skip to content

Commit e3ac386

Browse files
committed
updated formatting
Signed-off-by: lto-dev <[email protected]>
1 parent 4a935ea commit e3ac386

File tree

2 files changed

+18
-4
lines changed

2 files changed

+18
-4
lines changed

src/firewall/nft.rs

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,11 @@ impl firewall::FirewallDriver for Nftables {
381381
batch.add(make_rule(
382382
&chain,
383383
vec![
384-
get_subnet_match(&multicast_address, "daddr", stmt::Operator::NEQ),
384+
get_subnet_match(
385+
&multicast_address,
386+
"daddr",
387+
stmt::Operator::NEQ,
388+
),
385389
stmt::Statement::SNAT(Some(stmt::NAT {
386390
addr: Some(expr::Expression::String(addr.to_string())),
387391
family: Some(stmt::NATFamily::IP),
@@ -391,11 +395,18 @@ impl firewall::FirewallDriver for Nftables {
391395
],
392396
));
393397
} else {
394-
log::trace!("Outbound address {} is not IPv4, using default MASQUERADE rule", addr);
398+
log::trace!(
399+
"Outbound address {} is not IPv4, using default MASQUERADE rule",
400+
addr
401+
);
395402
batch.add(make_rule(
396403
&chain,
397404
vec![
398-
get_subnet_match(&multicast_address, "daddr", stmt::Operator::NEQ),
405+
get_subnet_match(
406+
&multicast_address,
407+
"daddr",
408+
stmt::Operator::NEQ,
409+
),
399410
stmt::Statement::Masquerade(None),
400411
],
401412
));

src/firewall/varktables/types.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,10 @@ pub fn get_network_chains<'a>(
231231
Some(TeardownPolicy::OnComplete),
232232
));
233233
} else {
234-
log::trace!("Outbound address {} is not IPv4, using default MASQUERADE rule", addr);
234+
log::trace!(
235+
"Outbound address {} is not IPv4, using default MASQUERADE rule",
236+
addr
237+
);
235238
hashed_network_chain.build_rule(VarkRule::new(
236239
format!("! -d {multicast_dest} -j {MASQUERADE}"),
237240
Some(TeardownPolicy::OnComplete),

0 commit comments

Comments
 (0)