rtp example: Fix leak

Also stop fetching the internal source as this
functionality has been broken.
This commit is contained in:
Olivier Crête 2016-07-11 11:59:19 -04:00
parent 6ca6a4111c
commit a390a6791c

View file

@ -88,13 +88,19 @@ on_ssrc_active_cb (GstElement * rtpbin, guint sessid, guint ssrc,
/* get the right session */ /* get the right session */
g_signal_emit_by_name (rtpbin, "get-internal-session", sessid, &session); g_signal_emit_by_name (rtpbin, "get-internal-session", sessid, &session);
#if 0
/* FIXME: This is broken in rtpbin */
/* get the internal source (the SSRC allocated to us, the receiver */ /* get the internal source (the SSRC allocated to us, the receiver */
g_object_get (session, "internal-source", &isrc, NULL); g_object_get (session, "internal-source", &isrc, NULL);
print_source_stats (isrc); print_source_stats (isrc);
g_object_unref (isrc);
#endif
/* get the remote source that sent us RTCP */ /* get the remote source that sent us RTCP */
g_signal_emit_by_name (session, "get-source-by-ssrc", ssrc, &osrc); g_signal_emit_by_name (session, "get-source-by-ssrc", ssrc, &osrc);
print_source_stats (osrc); print_source_stats (osrc);
g_object_unref (osrc);
g_object_unref (session);
} }
/* will be called when rtpbin has validated a payload that we can depayload */ /* will be called when rtpbin has validated a payload that we can depayload */