mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-09-09 00:00:08 +02:00
tokio: simplify Option handling with idiomatic combinators (#8336)
This commit is contained in:
@@ -1040,7 +1040,7 @@ impl Builder {
|
||||
|
||||
fn num_head_bytes(&self) -> usize {
|
||||
let num = self.length_field_offset + self.length_field_len;
|
||||
cmp::max(num, self.num_skip.unwrap_or(0))
|
||||
cmp::max(num, self.num_skip.unwrap_or_default())
|
||||
}
|
||||
|
||||
fn get_num_skip(&self) -> usize {
|
||||
|
||||
Reference in New Issue
Block a user