weight for SRV records should be at least 1 (#3931)
Automatically submitted.
This commit is contained in:
parent
86df1282cb
commit
4734c0db45
3 changed files with 14 additions and 1 deletions
|
@ -185,6 +185,10 @@ func SRV(ctx context.Context, b ServiceBackend, zone string, state request.Reque
|
|||
w1 *= float64(serv.Weight)
|
||||
}
|
||||
weight := uint16(math.Floor(w1))
|
||||
// weight should be at least 1
|
||||
if weight == 0 {
|
||||
weight = 1
|
||||
}
|
||||
|
||||
what, ip := serv.HostType()
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue