github.com/miekg/dns upgraded with code change
It had breaking changes, detailed in the reweave CHANGELOG
This commit is contained in:
1 parent
df2240acbd
commit
2f49b8455a
134 files changed
+25371
-6100
No files matched your search
+11
-1
@@ -1,7 +1,10 @@
|
||||
//go:build fuzz
|
||||
// +build fuzz
|
||||
|
||||
package dns
|
||||
|
||||
import "strings"
|
||||
|
||||
func Fuzz(data []byte) int {
|
||||
msg := new(Msg)
|
||||
|
||||
@@ -16,7 +19,14 @@ func Fuzz(data []byte) int {
|
||||
}
|
||||
|
||||
func FuzzNewRR(data []byte) int {
|
||||
if _, err := NewRR(string(data)); err != nil {
|
||||
str := string(data)
|
||||
// Do not fuzz lines that include the $INCLUDE keyword and hint the fuzzer
|
||||
// at avoiding them.
|
||||
// See GH#1025 for context.
|
||||
if strings.Contains(strings.ToUpper(str), "$INCLUDE") {
|
||||
return -1
|
||||
}
|
||||
if _, err := NewRR(str); err != nil {
|
||||
return 0
|
||||
}
|
||||
return 1
|
||||
|
||||
Reference in new issue
Block a user