Browse Source

Ensure we filter duplicate transports in muxer

Similar to secure transports in config, if we don't add the transport to
the set, we'll never identify duplicates.
pull/400/head
Raghav Gulati 6 years ago
parent
commit
3c19cb12b9
No known key found for this signature in database GPG Key ID: EA2C73F6F7EF2701
  1. 1
      config/muxer.go

1
config/muxer.go

@ -50,6 +50,7 @@ func makeMuxer(h host.Host, tpts []MsMuxC) (mux.Transport, error) {
if _, ok := transportSet[tptC.ID]; ok {
return nil, fmt.Errorf("duplicate muxer transport: %s", tptC.ID)
}
transportSet[tptC.ID] = struct{}{}
}
for _, tptC := range tpts {
tpt, err := tptC.MuxC(h)

Loading…
Cancel
Save