Skip to content

Commit

Permalink
add more debug info for dtls
Browse files Browse the repository at this point in the history
  • Loading branch information
yngrtc committed Mar 2, 2024
1 parent 21d52ae commit 0376d7a
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/handler/dtls.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,13 @@ impl InboundHandler for DtlsInbound {

let try_read = || -> Result<Vec<DtlsMessage>> {
let mut server_states = self.server_states.borrow_mut();
let transport = server_states.get_mut_transport(&four_tuple)?;
let transport = match server_states.get_mut_transport(&four_tuple) {
Ok(transport) => transport,
Err(err) => {
error!("get_mut_transport got error {}, it may be due to DTLS packet received earlier than STUN Binding Request", err);
return Err(err);
}
};
let mut io_messages = vec![];
let mut contexts = vec![];

Expand Down

0 comments on commit 0376d7a

Please sign in to comment.