mirror of
https://github.com/gogrlx/nats-server.git
synced 2026-04-02 03:38:42 -07:00
Merge pull request #3978 from nats-io/neil/encfix
Don't recycle buffer more than once
This commit is contained in:
@@ -4001,9 +4001,6 @@ func (mb *msgBlock) flushPendingMsgsLocked() (*LostStreamData, error) {
|
||||
dst = make([]byte, lob)
|
||||
}
|
||||
mb.bek.XORKeyStream(dst, buf)
|
||||
if cap(buf) <= defaultLargeBlockSize {
|
||||
recycleMsgBlockBuf(buf)
|
||||
}
|
||||
buf = dst
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user