Skip to content

Commit

Permalink
fix: Add trace log to session cleaner
Browse files Browse the repository at this point in the history
  • Loading branch information
alexculea committed May 23, 2024
1 parent 808be59 commit 0f4ed9a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/dhcp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,8 @@ fn start_session_cleaner(active_sessions: Arc<RwLock<SessionMap>>) {
drop(sessions); // unlock the RwLock
// would have been dropped anyway at the end of the loop
// but best to keep awareness of this happing to avoid deadlocks

trace!("Session cleaner removed {} timed out sessions.", items_to_remove.len());
}
});
}
Expand Down Expand Up @@ -256,7 +258,7 @@ async fn handle_dhcp_message(
let sessions = sessions.read().await;
let session = sessions.get(&client_xid);
if session.is_none() {
info!("No session found for client having XID: {}", client_xid)
info!("No session found for client having XID: {}", client_xid);
return Ok(())
}
let session = session.unwrap();
Expand Down

0 comments on commit 0f4ed9a

Please sign in to comment.