MCPcopy Create free account
hub / github.com/imroc/req / processSettings

Method processSettings

internal/http2/transport.go:2923–2938  ·  view source on GitHub ↗
(f *SettingsFrame)

Source from the content-addressed store, hash-verified

2921}
2922
2923func (rl *clientConnReadLoop) processSettings(f *SettingsFrame) error {
2924 cc := rl.cc
2925 // Locking both mu and wmu here allows frame encoding to read settings with only wmu held.
2926 // Acquiring wmu when f.IsAck() is unnecessary, but convenient and mostly harmless.
2927 cc.wmu.Lock()
2928 defer cc.wmu.Unlock()
2929
2930 if err := rl.processSettingsNoWrite(f); err != nil {
2931 return err
2932 }
2933 if !f.IsAck() {
2934 cc.fr.WriteSettingsAck()
2935 cc.bw.Flush()
2936 }
2937 return nil
2938}
2939
2940func (rl *clientConnReadLoop) processSettingsNoWrite(f *SettingsFrame) error {
2941 cc := rl.cc

Callers 1

runMethod · 0.95

Calls 5

LockMethod · 0.80
UnlockMethod · 0.80
WriteSettingsAckMethod · 0.80
IsAckMethod · 0.45

Tested by

no test coverage detected