From fc7a3038bd0ccae0b40f8f1b598386eb2b2e5028 Mon Sep 17 00:00:00 2001 From: KernelErr <45716019+KernelErr@users.noreply.github.com> Date: Mon, 1 Nov 2021 15:32:08 +0800 Subject: [PATCH] Add unknown protocol error --- src/servers/protocol/kcp.rs | 4 +++- src/servers/protocol/tcp.rs | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/servers/protocol/kcp.rs b/src/servers/protocol/kcp.rs index c5d3028..4272a20 100644 --- a/src/servers/protocol/kcp.rs +++ b/src/servers/protocol/kcp.rs @@ -89,7 +89,9 @@ async fn process( debug!("Bytes read: {:?} write: {:?}", bytes_tx, bytes_rx); } - _ => {} + _ => { + error!("Reached unknown protocol: {:?}", custom.protocol); + } } } }; diff --git a/src/servers/protocol/tcp.rs b/src/servers/protocol/tcp.rs index 99465bd..64c04f1 100644 --- a/src/servers/protocol/tcp.rs +++ b/src/servers/protocol/tcp.rs @@ -108,7 +108,9 @@ async fn process( debug!("Bytes read: {:?} write: {:?}", bytes_tx, bytes_rx); } - _ => {} + _ => { + error!("Reached unknown protocol: {:?}", custom.protocol); + } } } };