mirror of
https://github.com/aler9/gortsplib
synced 2025-10-05 07:06:58 +08:00
do not listen on IPv6 when host is 0.0.0.0 (#240)
(https://github.com/aler9/mediamtx/issues/1665)
This commit is contained in:
@@ -1232,8 +1232,8 @@ func (c *Client) doSetup(
|
||||
|
||||
err := cm.allocateUDPListeners(
|
||||
false,
|
||||
":"+strconv.FormatInt(int64(rtpPort), 10),
|
||||
":"+strconv.FormatInt(int64(rtcpPort), 10),
|
||||
net.JoinHostPort("", strconv.FormatInt(int64(rtpPort), 10)),
|
||||
net.JoinHostPort("", strconv.FormatInt(int64(rtcpPort), 10)),
|
||||
)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
@@ -1377,8 +1377,8 @@ func (c *Client) doSetup(
|
||||
|
||||
err := cm.allocateUDPListeners(
|
||||
true,
|
||||
thRes.Destination.String()+":"+strconv.FormatInt(int64(thRes.Ports[0]), 10),
|
||||
thRes.Destination.String()+":"+strconv.FormatInt(int64(thRes.Ports[1]), 10),
|
||||
net.JoinHostPort(thRes.Destination.String(), strconv.FormatInt(int64(thRes.Ports[0]), 10)),
|
||||
net.JoinHostPort(thRes.Destination.String(), strconv.FormatInt(int64(thRes.Ports[1]), 10)),
|
||||
)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
Reference in New Issue
Block a user