mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-23 15:48:23 +00:00
rtpsession: lock session when changing bandwidth
Take the session lock when changing the bandwidth properties so that we don't end up with inconsistent behaviour.
This commit is contained in:
parent
c337265ee4
commit
25e0f0d6b6
1 changed files with 8 additions and 0 deletions
|
@ -590,20 +590,28 @@ rtp_session_set_property (GObject * object, guint prop_id,
|
|||
rtp_session_set_internal_ssrc (sess, g_value_get_uint (value));
|
||||
break;
|
||||
case PROP_BANDWIDTH:
|
||||
RTP_SESSION_LOCK (sess);
|
||||
sess->bandwidth = g_value_get_double (value);
|
||||
sess->recalc_bandwidth = TRUE;
|
||||
RTP_SESSION_UNLOCK (sess);
|
||||
break;
|
||||
case PROP_RTCP_FRACTION:
|
||||
RTP_SESSION_LOCK (sess);
|
||||
sess->rtcp_bandwidth = g_value_get_double (value);
|
||||
sess->recalc_bandwidth = TRUE;
|
||||
RTP_SESSION_UNLOCK (sess);
|
||||
break;
|
||||
case PROP_RTCP_RR_BANDWIDTH:
|
||||
RTP_SESSION_LOCK (sess);
|
||||
sess->rtcp_rr_bandwidth = g_value_get_int (value);
|
||||
sess->recalc_bandwidth = TRUE;
|
||||
RTP_SESSION_UNLOCK (sess);
|
||||
break;
|
||||
case PROP_RTCP_RS_BANDWIDTH:
|
||||
RTP_SESSION_LOCK (sess);
|
||||
sess->rtcp_rs_bandwidth = g_value_get_int (value);
|
||||
sess->recalc_bandwidth = TRUE;
|
||||
RTP_SESSION_UNLOCK (sess);
|
||||
break;
|
||||
case PROP_RTCP_MTU:
|
||||
sess->mtu = g_value_get_uint (value);
|
||||
|
|
Loading…
Reference in a new issue