好难 好难 好难 ListenLoop的Sleeper为什么没有被唤醒

This commit is contained in:
impact-eintr
2022-12-07 21:28:51 +08:00
parent fa28cc3010
commit bea1fd210b
6 changed files with 22 additions and 29 deletions

View File

@@ -23,7 +23,7 @@ func (p Prependable) UsedLength() int {
return len(p.buf) - p.usedIdx
}
// 从内到外暴露报文头的协议 eth|ipv4|tcp
// Prepend 向前扩展size个字节
func (p *Prependable) Prepend(size int) []byte {
if size > p.usedIdx {
return nil