mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-18 14:26:43 +00:00
gst/rtpmanager/gstrtpbin.c: g_hash_table_remove_all() only exists in 2.12. Work around.
Original commit message from CVS: * gst/rtpmanager/gstrtpbin.c: g_hash_table_remove_all() only exists in 2.12. Work around.
This commit is contained in:
parent
62d401eb93
commit
720dfeb3a5
1 changed files with 11 additions and 0 deletions
|
@ -335,6 +335,12 @@ no_caps:
|
|||
}
|
||||
}
|
||||
|
||||
static gboolean
|
||||
return_true (gpointer key, gpointer value, gpointer user_data)
|
||||
{
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
static void
|
||||
gst_rtp_bin_clear_pt_map (GstRTPBin * bin)
|
||||
{
|
||||
|
@ -345,7 +351,12 @@ gst_rtp_bin_clear_pt_map (GstRTPBin * bin)
|
|||
GstRTPBinSession *session = (GstRTPBinSession *) walk->data;
|
||||
|
||||
GST_RTP_SESSION_LOCK (session);
|
||||
#if 0
|
||||
/* This requires GLib 2.12 */
|
||||
g_hash_table_remove_all (session->ptmap);
|
||||
#else
|
||||
g_hash_table_foreach_remove (session->ptmap, return_true, NULL);
|
||||
#endif
|
||||
GST_RTP_SESSION_UNLOCK (session);
|
||||
}
|
||||
GST_RTP_BIN_UNLOCK (bin);
|
||||
|
|
Loading…
Reference in a new issue