This commit is contained in:
shoopea 2020-06-14 17:38:58 +02:00
parent 5447c59d81
commit 1ea23d65f3

2
def.go
View File

@ -58,7 +58,7 @@ type PacketAdminJoin struct {
func (p *PacketAdminJoin) Bytes() []byte { func (p *PacketAdminJoin) Bytes() []byte {
buf := new(bytes.Buffer) buf := new(bytes.Buffer)
p.PLength = uint16(len(p.Password) + len(p.AppName) + len(p.AppVersion) + 3) p.PLength = uint16(len(p.Password) + len(p.AppName) + len(p.AppVersion) + 6)
binary.Write(buf, binary.LittleEndian, p.PLength) binary.Write(buf, binary.LittleEndian, p.PLength)
logInfoDebug("len : %d", buf.Len()) logInfoDebug("len : %d", buf.Len())