Skip to content

Commit

Permalink
feat: fix bug that len(last payloads) is less than 5
Browse files Browse the repository at this point in the history
  • Loading branch information
HarryWang29 committed Sep 15, 2023
1 parent c2a03ae commit 3888fad
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion proto/proto.go
Original file line number Diff line number Diff line change
Expand Up @@ -559,7 +559,7 @@ func HasFullPayload(m ProtocolStateSetter, payloads ...[]byte) bool {
}

// check trailer headers
toCheck := getCheckBytes()
toCheck := getCheckBytes(payloads...)
if state.HasTrailer {
if bytes.HasSuffix(toCheck, []byte("\r\n\r\n")) {
return true
Expand Down

0 comments on commit 3888fad

Please sign in to comment.