Skip to content

Commit

Permalink
Implement MaxSize for xwt-anchor
Browse files Browse the repository at this point in the history
  • Loading branch information
MOZGIII committed Aug 8, 2024
1 parent 7b02468 commit 5585f8a
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions crates/xwt-anchor/src/impls/xwt_core/session_datagrams.rs
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,12 @@ where
T::send_datagram(&self.0, payload).await
}
}

impl<T> xwt_core::session::datagram::MaxSize for Session<T>
where
T: xwt_core::session::datagram::MaxSize + maybe::Send + maybe::Sync,
{
fn max_datagram_size(&self) -> Option<usize> {
T::max_datagram_size(&self.0)
}
}

0 comments on commit 5585f8a

Please sign in to comment.