From 9af53da5c3a25d4a5c144a10a504310b3719d6b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Linus=20F=C3=A4rnstrand?= Date: Wed, 18 Dec 2024 15:58:57 +0100 Subject: [PATCH] Add more debug logging --- src/forward_traffic.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/forward_traffic.rs b/src/forward_traffic.rs index 7c9d28d..1c3d07a 100644 --- a/src/forward_traffic.rs +++ b/src/forward_traffic.rs @@ -70,6 +70,7 @@ pub async fn process_tcp2udp( .await .context("Timeout while reading from TCP")? .context("Failed reading from TCP")?; + log::info!("TCP2UDP read {} bytes from TCP socket", tcp_read_len); if tcp_read_len == 0 { break; } @@ -145,6 +146,7 @@ pub async fn process_udp2tcp( .recv(&mut buffer[HEADER_LEN..]) .await .context("Failed reading from UDP")?; + log::info!("UDP2TCP read {} bytes from UDP socket", udp_read_len); // Set the "header" to the length of the datagram. let datagram_len =