We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent acb3aba commit 66f2f27Copy full SHA for 66f2f27
edns.go
@@ -81,17 +81,16 @@ type OPT struct {
81
82
func (rr *OPT) String() string {
83
s := "\n;; OPT PSEUDOSECTION:\n; EDNS: version " + strconv.Itoa(int(rr.Version())) + "; "
84
+ s += "flags:"
85
if rr.Do() {
- if rr.Co() {
86
- s += "flags: do, co; "
87
- } else {
88
- s += "flags: do; "
89
- }
90
91
- s += "flags:; "
+ s += " do"
+ }
+ if rr.Co() {
+ s += " co"
92
}
93
- if rr.Hdr.Ttl&0x7FFF != 0 {
94
- s += fmt.Sprintf("MBZ: 0x%04x, ", rr.Hdr.Ttl&0x7FFF)
+ s += "; "
+ if z := rr.Z(); z != 0 {
+ s += fmt.Sprintf("MBZ: 0x%04x, ", z)
95
96
s += "udp: " + strconv.Itoa(int(rr.UDPSize()))
97
0 commit comments