fix: eliminate stale verdict poisoning, memory leaks, data races, and per-packet allocations in engine
This commit is contained in:
@@ -14,6 +14,7 @@ import (
|
||||
const (
|
||||
quicInvalidCountThreshold = 16
|
||||
quicMaxCryptoDataLen = 256 * 1024
|
||||
quicMaxFrameEntries = 100
|
||||
)
|
||||
|
||||
var (
|
||||
@@ -158,6 +159,9 @@ func (s *quicStream) mergeFrame(offset int64, data []byte) {
|
||||
if len(data) == 0 || offset < 0 {
|
||||
return
|
||||
}
|
||||
if len(s.frames) >= quicMaxFrameEntries {
|
||||
return
|
||||
}
|
||||
if s.frames == nil {
|
||||
s.frames = make(map[int64][]byte)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user