From 8779ce5f960d4858a3f2ddd695432b1f4f5600f4 Mon Sep 17 00:00:00 2001 From: Pavel Merzlyakov Date: Thu, 27 Jul 2023 02:04:35 +0300 Subject: [PATCH] fix reading mask --- msgpack_reader.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/msgpack_reader.go b/msgpack_reader.go index a9a0df5..a3afebe 100644 --- a/msgpack_reader.go +++ b/msgpack_reader.go @@ -530,6 +530,10 @@ func (rd *msgpackReader) Skip() error { } func (rd *msgpackReader) TryReadMask() (bool, FieldsMask, error) { + if rd.curr.assoc { + return false, FieldsMask{}, nil + } + maskLen, err := rd.dec.DecodeArrayLen() if err != nil { if err == io.EOF {