Skip to content

Commit f7a866a

Browse files
committed
style: reformat code for improved readability
1 parent b22cdb7 commit f7a866a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/parser/mrt/messages/table_dump_v2/rib_afi_entries.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,8 @@ pub fn parse_rib_afi_entries(
6262

6363
let entry_count = data.read_u16()?;
6464
// Pre-allocate cautiously to avoid overflow/OOM with malformed inputs
65-
let min_entry_size = 2 /*peer_index*/ + 4 /*time*/ + 2 /*attr_len*/ + if is_add_path { 4 } else { 0 };
65+
let min_entry_size =
66+
2 /*peer_index*/ + 4 /*time*/ + 2 /*attr_len*/ + if is_add_path { 4 } else { 0 };
6667
let max_possible = data.remaining() / min_entry_size;
6768
let reserve = (entry_count as usize).min(max_possible).saturating_mul(2);
6869
let mut rib_entries = Vec::with_capacity(reserve);

0 commit comments

Comments
 (0)