MCPcopy
hub / github.com/jackc/pgx / FuzzParse

Function FuzzParse

pgproto3/fuzz_test.go:158–165  ·  view source on GitHub ↗
(f *testing.F)

Source from the content-addressed store, hash-verified

156}
157
158func FuzzParse(f *testing.F) {
159 f.Add([]byte{0, 0, 0, 0})
160 f.Add([]byte{})
161 f.Fuzz(func(t *testing.T, data []byte) {
162 var msg pgproto3.Parse
163 msg.Decode(data) // must not panic
164 })
165}
166
167func FuzzQuery(f *testing.F) {
168 f.Add([]byte("SELECT 1\x00"))

Callers

nothing calls this directly

Calls 1

DecodeMethod · 0.95

Tested by

no test coverage detected