Commit 72844416 authored by Aurélien Zanelli's avatar Aurélien Zanelli Committed by Tim-Philipp Müller

av: use GMutex instead of deprecated GStaticMutex

https://bugzilla.gnome.org/show_bug.cgi?id=740822
parent 70462960
......@@ -36,7 +36,7 @@
GST_DEBUG_CATEGORY (ffmpeg_debug);
static GStaticMutex gst_avcodec_mutex = G_STATIC_MUTEX_INIT;
static GMutex gst_avcodec_mutex;
int
......@@ -44,9 +44,9 @@ gst_ffmpeg_avcodec_open (AVCodecContext * avctx, AVCodec * codec)
{
int ret;
g_static_mutex_lock (&gst_avcodec_mutex);
g_mutex_lock (&gst_avcodec_mutex);
ret = avcodec_open2 (avctx, codec, NULL);
g_static_mutex_unlock (&gst_avcodec_mutex);
g_mutex_unlock (&gst_avcodec_mutex);
return ret;
}
......@@ -56,9 +56,9 @@ gst_ffmpeg_avcodec_close (AVCodecContext * avctx)
{
int ret;
g_static_mutex_lock (&gst_avcodec_mutex);
g_mutex_lock (&gst_avcodec_mutex);
ret = avcodec_close (avctx);
g_static_mutex_unlock (&gst_avcodec_mutex);
g_mutex_unlock (&gst_avcodec_mutex);
return ret;
}
......@@ -68,9 +68,9 @@ gst_ffmpeg_av_find_stream_info (AVFormatContext * ic)
{
int ret;
g_static_mutex_lock (&gst_avcodec_mutex);
g_mutex_lock (&gst_avcodec_mutex);
ret = avformat_find_stream_info (ic, NULL);
g_static_mutex_unlock (&gst_avcodec_mutex);
g_mutex_unlock (&gst_avcodec_mutex);
return ret;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment