mirror of
https://github.com/threefoldtech/mycelium.git
synced 2026-06-04 06:41:31 +00:00
Avoid cloning packet on receive apth
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
This commit is contained in:
+1
-4
@@ -228,10 +228,7 @@ async fn main() -> Result<(), Box<dyn Error>> {
|
||||
while let Some(packet) = tun_rx.recv().await {
|
||||
trace!("received packet from tun_rx");
|
||||
if let Err(e) = txhalf.send(packet.clone().into()).await {
|
||||
error!(
|
||||
"Failed to send packet on local TUN interface: {e} - {}",
|
||||
faster_hex::hex_string(&packet)
|
||||
);
|
||||
error!("Failed to send packet on local TUN interface: {e}",);
|
||||
continue;
|
||||
}
|
||||
trace!("Sent packet on tun interface");
|
||||
|
||||
Reference in New Issue
Block a user