techniques for handling timeouts when using dtlssrtpenc, nicesink, dtlssrtpdec, and nicesrc

Matt Pekar mpekar at
Tue May 9 16:13:57 UTC 2017

I'm working on a WebRTC pipeline and having trouble handling timeouts to
broken connections with these elements.  One end of the connection is a
Chrome webpage that sends the webrtc "offer".  The "answer" side is a
custom GStreamer application that is roughly this:

  H264DATA ! queue ! h264parse ! rtph264pay ! rtpbin name=rtp ! dtlssrtpenc
! nicesink

  nicesrc ! dtlssrtpdec ! rtp.

As far as I can tell there is a handle_timeout() callback in
gstdtlsconnection.c that is getting invoked, but the result of the
DTLSv1_handle_timeout() call is being logged then ignored:

  if (priv->is_alive) {
    ret = DTLSv1_handle_timeout (priv->ssl);

    GST_DEBUG_OBJECT (self, "handle timeout returned %d, is_alive: %d", ret,

    if (ret < 0) {
      GST_WARNING_OBJECT (self, "handling timeout failed");
    } else if (ret > 0) {
      log_state (self, "handling timeout before poll");
      openssl_poll (self);
      log_state (self, "handling timeout after poll");

Is there an appropriate way to check for loss of connectivity with these
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the gstreamer-devel mailing list