Unverified Commit 87255e4f authored by Raghav Gulati's avatar Raghav Gulati
Browse files

Ensure duplicate transports are filtered

Without adding the transport to the set, we'll never identify if there
are duplicates in the slice of secure transports provided by the config.
parent 6f0dcfa1
......@@ -61,6 +61,7 @@ func makeSecurityTransport(h host.Host, tpts []MsSecC) (security.Transport, erro
if _, ok := transportSet[tptC.ID]; ok {
return nil, fmt.Errorf("duplicate security transport: %s", tptC.ID)
}
transportSet[tptC.ID] = tptC
}
for _, tptC := range tpts {
tpt, err := tptC.SecC(h)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment