mirror of
https://github.com/fumiama/WireGold.git
synced 2026-06-04 23:40:26 +08:00
chore: make lint happy
This commit is contained in:
@@ -51,7 +51,7 @@ func (p *Packet) WriteHeaderTo(buf *bytes.Buffer) {
|
||||
(unsafe.Pointer)(p),
|
||||
)[:])
|
||||
p.md5h8rem = int64(algo.MD5Hash8(buf.Bytes()))
|
||||
binary.Write(buf, binary.LittleEndian, p.md5h8rem)
|
||||
_ = binary.Write(buf, binary.LittleEndian, p.md5h8rem)
|
||||
return
|
||||
}
|
||||
w := bin.SelectWriter()
|
||||
@@ -68,6 +68,6 @@ func (p *Packet) WriteHeaderTo(buf *bytes.Buffer) {
|
||||
})
|
||||
w.WriteUInt64(uint64(p.md5h8rem))
|
||||
w.P(func(b *pbuf.Buffer) {
|
||||
buf.ReadFrom(b)
|
||||
_, _ = buf.ReadFrom(b)
|
||||
})
|
||||
}
|
||||
|
||||
@@ -137,7 +137,7 @@ func (pb *DataBuilder) Plain(teatyp uint8, additional uint16) *PacketBuilder {
|
||||
w.Write(ub.Bytes())
|
||||
w.P(func(b *pbuf.Buffer) {
|
||||
ub.Reset()
|
||||
ub.ReadFrom(b)
|
||||
_, _ = ub.ReadFrom(b)
|
||||
})
|
||||
}))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user