[libnice] Detecting the peer has disconnected

Philip Withnall philip at tecnocode.co.uk
Fri Apr 24 02:34:40 PDT 2015


On Wed, 2015-04-22 at 15:40 +0000, Curieux Tres wrote:

> I have 2 instances of libnice talking to each other nicely
> But when one of the instance is killed, the other one is not notified
> and retries forever to send data.
> What would be the right way to get that "peer is gone" information ?
> I've hooked all the signals but they are not invoked in that case
> (might have made a mistake there).

PseudoTcpSocket has supported this since libnice 0.1.8, using its FIN–
ACK support.

Make sure PseudoTcpSocket:support-fin-ack is set to TRUE.
pseudo_tcp_socket_recv() should return 0 when the remote peer has called
pseudo_tcp_socket_close(). You can also check this using


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 213 bytes
Desc: This is a digitally signed message part
URL: <http://lists.freedesktop.org/archives/nice/attachments/20150424/f181c825/attachment.sig>

More information about the nice mailing list