mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-25 09:40:37 +00:00
gstminiobject: shares capacity increase
during the MSE (WebKit) tests from Apple suite: https://hls-streaming.cdn-apple.com/hls_conformance/dist/v1.1/index.html?pretty=true&whitelist=MSE%20Suite webkit attempts to add a single audio buffer containing ~35.5k frames. when corresponding GstSamples are pulled buffer is being referenced more than object capacity allows: 2^15-1. since the case could be considered malformed a surgical patch is applied to increase the capacity. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3233>
This commit is contained in:
parent
e144ec015e
commit
b7ae311c75
1 changed files with 7 additions and 7 deletions
|
@ -217,7 +217,7 @@ gst_mini_object_copy (const GstMiniObject * mini_object)
|
|||
gboolean
|
||||
gst_mini_object_lock (GstMiniObject * object, GstLockFlags flags)
|
||||
{
|
||||
gint access_mode, state, newstate;
|
||||
guint access_mode, state, newstate;
|
||||
|
||||
g_return_val_if_fail (object != NULL, FALSE);
|
||||
g_return_val_if_fail (GST_MINI_OBJECT_IS_LOCKABLE (object), FALSE);
|
||||
|
@ -228,9 +228,9 @@ gst_mini_object_lock (GstMiniObject * object, GstLockFlags flags)
|
|||
|
||||
do {
|
||||
access_mode = flags & FLAG_MASK;
|
||||
newstate = state = g_atomic_int_get (&object->lockstate);
|
||||
newstate = state = (guint) g_atomic_int_get (&object->lockstate);
|
||||
|
||||
GST_CAT_TRACE (GST_CAT_LOCKING, "lock %p: state %08x, access_mode %d",
|
||||
GST_CAT_TRACE (GST_CAT_LOCKING, "lock %p: state %08x, access_mode %u",
|
||||
object, state, access_mode);
|
||||
|
||||
if (access_mode & GST_LOCK_FLAG_EXCLUSIVE) {
|
||||
|
@ -265,7 +265,7 @@ gst_mini_object_lock (GstMiniObject * object, GstLockFlags flags)
|
|||
lock_failed:
|
||||
{
|
||||
GST_CAT_DEBUG (GST_CAT_LOCKING,
|
||||
"lock failed %p: state %08x, access_mode %d", object, state,
|
||||
"lock failed %p: state %08x, access_mode %u", object, state,
|
||||
access_mode);
|
||||
return FALSE;
|
||||
}
|
||||
|
@ -281,16 +281,16 @@ lock_failed:
|
|||
void
|
||||
gst_mini_object_unlock (GstMiniObject * object, GstLockFlags flags)
|
||||
{
|
||||
gint access_mode, state, newstate;
|
||||
guint access_mode, state, newstate;
|
||||
|
||||
g_return_if_fail (object != NULL);
|
||||
g_return_if_fail (GST_MINI_OBJECT_IS_LOCKABLE (object));
|
||||
|
||||
do {
|
||||
access_mode = flags & FLAG_MASK;
|
||||
newstate = state = g_atomic_int_get (&object->lockstate);
|
||||
newstate = state = (guint) g_atomic_int_get (&object->lockstate);
|
||||
|
||||
GST_CAT_TRACE (GST_CAT_LOCKING, "unlock %p: state %08x, access_mode %d",
|
||||
GST_CAT_TRACE (GST_CAT_LOCKING, "unlock %p: state %08x, access_mode %u",
|
||||
object, state, access_mode);
|
||||
|
||||
if (access_mode & GST_LOCK_FLAG_EXCLUSIVE) {
|
||||
|
|
Loading…
Reference in a new issue