Skip to content

Commit

Permalink
Allocate new buffer for every package (#2823)
Browse files Browse the repository at this point in the history
  • Loading branch information
pappz authored Oct 31, 2024
1 parent ad4f0a6 commit 9812de8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion client/iface/wgproxy/bind/proxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,8 @@ func (p *ProxyBind) proxyToLocal(ctx context.Context) {
}
}()

buf := make([]byte, 1500)
for {
buf := make([]byte, 1500)
n, err := p.remoteConn.Read(buf)
if err != nil {
if ctx.Err() != nil {
Expand Down

0 comments on commit 9812de8

Please sign in to comment.