mirror of
https://github.com/StackExchange/dnscontrol.git
synced 2024-05-11 05:55:12 +00:00
BIND: Improve SOA serial number handling (#651)
* github.com/miekg/dns * Greatly simplify the logic for handling serial numbers. Related code was all over the place. Now it is abstracted into one testable method makeSoa. This simplifies code in many other places. * Update docs/_providers/bind.md: Edit old text. Add SOA description. * SOA records are now treated like any other record internally. You still can't specify them in dnsconfig.js, but that's by design. * The URL for issue 491 was wrong in many places * BIND: Clarify GENERATE_ZONEFILE message
This commit is contained in:
@ -3,8 +3,6 @@ package models
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/gob"
|
||||
"fmt"
|
||||
"strconv"
|
||||
)
|
||||
|
||||
func copyObj(input interface{}, output interface{}) error {
|
||||
@ -16,13 +14,3 @@ func copyObj(input interface{}, output interface{}) error {
|
||||
}
|
||||
return dec.Decode(output)
|
||||
}
|
||||
|
||||
// atou32 converts a string to uint32 or panics.
|
||||
// DEPRECATED: This will go away when SOA record handling is rewritten.
|
||||
func atou32(s string) uint32 {
|
||||
i64, err := strconv.ParseUint(s, 10, 32)
|
||||
if err != nil {
|
||||
panic(fmt.Errorf("atou32 failed (%v) (err=%v", s, err))
|
||||
}
|
||||
return uint32(i64)
|
||||
}
|
||||
|
Reference in New Issue
Block a user