Skip to content

Commit

Permalink
Add missing priority in the HEADER frame (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
hellodword committed Apr 22, 2024
1 parent b9869b3 commit f0b7407
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions pkg/http2/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -1544,6 +1544,15 @@ func (sc *serverConn) processFrame(f Frame) error {
headers = append(headers, metadata.HeaderField(h))
}
md.HTTP2Frames.Headers = headers
if f.HasPriority() {
md.HTTP2Frames.Priorities = append(md.HTTP2Frames.Priorities,
metadata.Priority{
StreamId: f.StreamID,
StreamDep: f.Priority.StreamDep,
Exclusive: f.Priority.Exclusive,
Weight: f.Priority.Weight,
})
}
}
return sc.processHeaders(f)
case *WindowUpdateFrame:
Expand Down

0 comments on commit f0b7407

Please sign in to comment.