more copys

This commit is contained in:
Miek Gieben 2012-06-20 14:32:23 +02:00
parent 331276b2b1
commit a6f42f338a
1 changed files with 8 additions and 0 deletions

View File

@ -466,6 +466,10 @@ func (rr *RR_RP) Len() int {
return rr.Hdr.Len() + len(rr.Mbox) + 1 + len(rr.Txt) + 1
}
func (rr *RR_RP) Copy() *RR_RP {
return &RR_RP{*rr.Hdr.Copy(), rr.Mbox, rr.Txt}
}
type RR_SOA struct {
Hdr RR_Header
Ns string `dns:"cdomain-name"`
@ -496,6 +500,10 @@ func (rr *RR_SOA) Len() int {
return rr.Hdr.Len() + l + n + 20
}
func (rr *RR_SOA) Copy() *RR_SOA {
return &RR_SOA{*rr.Hdr.Copy(), rr.Ns, rr.Mbox, rr.Serial, rr.Refresh, rr.Retry, rr.Expire, rr.Minttl}
}
type RR_TXT struct {
Hdr RR_Header
Txt []string `dns:"txt"`