mirror of
https://github.com/MetaCubeX/Clash.Meta.git
synced 2025-04-11 04:50:56 +00:00
fix: buffer release
This commit is contained in:
parent
a1e1e99451
commit
fab0ce10cb
2 changed files with 4 additions and 0 deletions
|
@ -135,6 +135,8 @@ func (l *Listener) HandleConn(conn net.Conn, h *sing.ListenerHandler) {
|
|||
defer conn.Close()
|
||||
|
||||
b := buf.NewPacket()
|
||||
defer b.Release()
|
||||
|
||||
_, err := b.ReadOnceFrom(conn)
|
||||
if err != nil {
|
||||
return
|
||||
|
|
|
@ -71,6 +71,8 @@ func (c *Client) CreateOutboundTLSConnection(ctx context.Context) (net.Conn, err
|
|||
}
|
||||
|
||||
b := buf.NewPacket()
|
||||
defer b.Release()
|
||||
|
||||
b.Write(c.passwordSha256)
|
||||
var paddingLen int
|
||||
if pad := c.padding.Load().GenerateRecordPayloadSizes(0); len(pad) > 0 {
|
||||
|
|
Loading…
Add table
Reference in a new issue