Files
fasthttp/fuzzit/url/url_fuzz.go
T
Erik Dubbelboer ac4cc171a5 Completely remove fuzzit
They have been acquired by GitLab and are going to remove all data for
previous projects. See https://github.com/valyala/fasthttp/issues/838
2020-06-21 10:55:27 +02:00

24 lines
285 B
Go

// +build gofuzz
package fuzz
import (
"bytes"
"github.com/valyala/fasthttp"
)
func Fuzz(data []byte) int {
u := fasthttp.AcquireURI()
defer fasthttp.ReleaseURI(u)
u.UpdateBytes(data)
w := bytes.Buffer{}
if _, err := u.WriteTo(&w); err != nil {
return 0
}
return 1
}