pull/927/head
Darien Raymond 2018-03-04 21:06:04 +01:00
parent a52eb8f82b
commit 9100a78914
No known key found for this signature in database
GPG Key ID: 7251FFA14BB18169
2 changed files with 2 additions and 2 deletions

View File

@ -172,7 +172,7 @@ func (p *AddressParser) writeAddress(writer io.Writer, address net.Address) erro
} }
case net.AddressFamilyDomain: case net.AddressFamilyDomain:
domain := address.Domain() domain := address.Domain()
if IsDomainTooLong(domain) { if isDomainTooLong(domain) {
return newError("Super long domain is not supported: ", domain) return newError("Super long domain is not supported: ", domain)
} }
if _, err := writer.Write([]byte{tb, byte(len(domain))}); err != nil { if _, err := writer.Write([]byte{tb, byte(len(domain))}); err != nil {

View File

@ -85,6 +85,6 @@ func (sc *SecurityConfig) GetSecurityType() SecurityType {
return sc.Type return sc.Type
} }
func IsDomainTooLong(domain string) bool { func isDomainTooLong(domain string) bool {
return len(domain) > 256 return len(domain) > 256
} }