mirror of
https://github.com/soypat/lneto.git
synced 2026-09-10 00:29:34 +00:00
Further improvements to httphi API (#173)
* add Exchange.WriteBodyString * Mux.MaxPathValues and other improvements * Mux PathValue improvemnt and fixes * MuxSlice more method muxing improvements * diagram out interesting approach to form parsing for clanker * refactor RequestParseForm and achieve greatness in API design * explicit naming of headerCapacityKV value in kvBuffer.Reset * fix Mux bug not matching paths correctly; httpraw HTTP V1 naming applied * rename many examples,use httphi in examples,remove useless maxAwaitingConn field * add ipv4.String * add ipv4 UnspecifiedAddr and BroadcastAddr * add ethernet.String
This commit is contained in:
@@ -21,7 +21,7 @@ func FuzzStackPacketHTTP(f *testing.F) {
|
||||
const seed = 1
|
||||
var buf [ethernet.MaxFrameLength]byte
|
||||
s1, s2, c1, c2 := newTCPStacks(f, seed, MTU)
|
||||
var hdr httpraw.Header
|
||||
var hdr httpraw.HeaderV1
|
||||
err := s1.ListenTCP4(c1, 80)
|
||||
if err != nil {
|
||||
f.Fatal(err)
|
||||
@@ -129,7 +129,7 @@ func FuzzStackPacketHTTP(f *testing.F) {
|
||||
if n1 == 0 && n2 == 0 {
|
||||
if !closed {
|
||||
if c1.BufferedInput() > 0 {
|
||||
var hdr httpraw.Header
|
||||
var hdr httpraw.HeaderV1
|
||||
n, _ := c1.Read(buf[:])
|
||||
hdr.ReadFromBytes(buf[:n])
|
||||
hdr.TryParse(false)
|
||||
|
||||
Reference in New Issue
Block a user