Skip to content

Commit

Permalink
fuzz: ignore roundtrip err till 1.23 lands (#409)
Browse files Browse the repository at this point in the history
  • Loading branch information
manunio authored May 23, 2024
1 parent 1e2c053 commit a645c7b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions ossfuzz/fuzz.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package ossfuzz
import (
"bytes"
"fmt"
"strings"

"github.com/BurntSushi/toml"
)
Expand All @@ -27,6 +28,11 @@ func FuzzToml(data []byte) int {
var v2 any
_, err = toml.Decode(buf.String(), &v2)
if err != nil {
// TODO(manunio): remove this when 1.23 lands, see #407.
if strings.Contains(err.Error(), "invalid datetime") {
return 0
}

panic(fmt.Sprintf("failed round trip: %s", err))
}

Expand Down

0 comments on commit a645c7b

Please sign in to comment.