mirror of
https://github.com/caddyserver/caddy.git
synced 2025-05-24 02:02:26 -04:00
v2: fuzz: update function signature of caddyfile.Parse (#3160)
This commit is contained in:
parent
42a6628935
commit
61b427fa47
@ -17,12 +17,8 @@
|
|||||||
|
|
||||||
package caddyfile
|
package caddyfile
|
||||||
|
|
||||||
import (
|
|
||||||
"bytes"
|
|
||||||
)
|
|
||||||
|
|
||||||
func FuzzParseCaddyfile(data []byte) (score int) {
|
func FuzzParseCaddyfile(data []byte) (score int) {
|
||||||
sb, err := Parse("Caddyfile", bytes.NewReader(data))
|
sb, err := Parse("Caddyfile", data)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
// if both an error is received and some ServerBlocks,
|
// if both an error is received and some ServerBlocks,
|
||||||
// then the parse was able to parse partially. Mark this
|
// then the parse was able to parse partially. Mark this
|
||||||
|
Loading…
x
Reference in New Issue
Block a user