feat: Adds socket from the single-port and TCP harvesters to the Component.
This commit is contained in:
parent
2718728e92
commit
25b0cfdc30
@ -362,6 +362,12 @@ public class SinglePortUdpHarvester
|
||||
stunSocket,
|
||||
new TransportAddress(remoteAddress, Transport.UDP));
|
||||
|
||||
// TODO: maybe move this code to the candidates.
|
||||
MergingDatagramSocket componentSocket = component.getSocket();
|
||||
if (componentSocket != null)
|
||||
{
|
||||
componentSocket.add(multiplexing);
|
||||
}
|
||||
|
||||
// XXX is this necessary?
|
||||
synchronized (candidateSockets)
|
||||
|
||||
@ -518,6 +518,13 @@ public class TcpHarvester
|
||||
component.getParentStream().getParentAgent().getStunStack()
|
||||
.addSocket(stunSocket);
|
||||
candidate.addSocket(candidateSocket);
|
||||
|
||||
// TODO: Maybe move this code to the candidate.
|
||||
MergingDatagramSocket componentSocket = component.getSocket();
|
||||
if (componentSocket != null)
|
||||
{
|
||||
componentSocket.add(multiplexing);
|
||||
}
|
||||
// the socket is not our responsibility anymore. It is up to
|
||||
// the candidate/component to close/free it.
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user