more printing tweaks for OPT

This commit is contained in:
Miek Gieben 2010-12-23 14:43:26 +01:00
parent e32a3784f2
commit e5a394b97e
3 changed files with 1 additions and 4 deletions

View File

@ -79,7 +79,6 @@ func TestPackUnpack(t *testing.T) {
}
edns := new(RR_OPT)
edns.Hdr.Edns = true
edns.Hdr.Name = "."
edns.Hdr.Rrtype = TypeOPT
edns.Hdr.Class = ClassINET

View File

@ -21,7 +21,6 @@ func TestResolverEdns(t *testing.T) {
// Add EDNS rr
edns := new(RR_OPT)
edns.Hdr.Edns = true // must be set for edns
edns.Hdr.Name = "." // must . be for edns
edns.Hdr.Rrtype = TypeOPT
edns.Hdr.Class = ClassINET

View File

@ -120,7 +120,6 @@ func (q *Question) String() string {
// There are many types of messages,
// but they all share the same header.
type RR_Header struct {
Edns bool // true is this a edns header
Name string "domain-name"
Rrtype uint16
Class uint16
@ -135,7 +134,7 @@ func (h *RR_Header) Header() *RR_Header {
func (h *RR_Header) String() string {
var s string
if h.Edns {
if h.Rrtype == TypeOPT {
s = ";"
}