add more details to errors

This commit is contained in:
aler9
2021-01-29 12:51:25 +01:00
parent 0af60f95f8
commit ec3002e995
2 changed files with 4 additions and 2 deletions

View File

@@ -53,7 +53,8 @@ func (h *Header) read(rb *bufio.Reader) error {
}
if len(*h) >= headerMaxEntryCount {
return fmt.Errorf("headers count exceeds %d", headerMaxEntryCount)
return fmt.Errorf("headers count exceeds %d (it's %d)",
headerMaxEntryCount, len(*h))
}
key := string([]byte{byt})