From 7929c28b7d5ecfdc7f236060b9b554a0d655da31 Mon Sep 17 00:00:00 2001 From: Max Date: Tue, 23 Apr 2024 23:34:59 +0200 Subject: [PATCH] packages/hyprspace: allocate multiple packets --- packages/networking/hyprspace/cli/up.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/networking/hyprspace/cli/up.go b/packages/networking/hyprspace/cli/up.go index 803ad01..301234f 100644 --- a/packages/networking/hyprspace/cli/up.go +++ b/packages/networking/hyprspace/cli/up.go @@ -177,8 +177,8 @@ func UpRun(r *cmd.Root, c *cmd.Sub) { // Initialize active streams map and packet byte array. activeStreams = make(map[peer.ID]MuxStream) - var packet = make([]byte, 1420) for { + var packet = make([]byte, 1420) // Read in a packet from the tun device. plen, err := tunDev.Iface.Read(packet) if errors.Is(err, fs.ErrClosed) {