summaryrefslogtreecommitdiff
path: root/libavcodec
diff options
context:
space:
mode:
authorwm4 <nfxjfg@googlemail.com>2017-12-21 22:54:06 +0100
committerwm4 <nfxjfg@googlemail.com>2017-12-26 02:50:00 +0100
commit86a13bf2ffb40d44260d5747a4782a42a43a1ed8 (patch)
treecb6310c0db5956b5c8567cd9e99e6c2799ce90e0 /libavcodec
parente24f192a9fd6013e272df1bfaeaba31e8ca49f92 (diff)
lavc, lavf: move avformat static mutex from avcodec to avformat
It's completely absurd that libavcodec would care about libavformat locking, but it was there because the lock manager was in libavcodec. This is more stright forward. Changes ABI, but we don't require ABI compatibility currently.
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/internal.h3
-rw-r--r--libavcodec/utils.c11
2 files changed, 0 insertions, 14 deletions
diff --git a/libavcodec/internal.h b/libavcodec/internal.h
index fcbdb6c04d..30614bb2b1 100644
--- a/libavcodec/internal.h
+++ b/libavcodec/internal.h
@@ -247,9 +247,6 @@ extern volatile int ff_avcodec_locked;
int ff_lock_avcodec(AVCodecContext *log_ctx, const AVCodec *codec);
int ff_unlock_avcodec(const AVCodec *codec);
-int avpriv_lock_avformat(void);
-int avpriv_unlock_avformat(void);
-
/**
* Maximum size in bytes of extradata.
* This value was chosen such that every bit of the buffer is
diff --git a/libavcodec/utils.c b/libavcodec/utils.c
index eec4437693..9c631c4fb0 100644
--- a/libavcodec/utils.c
+++ b/libavcodec/utils.c
@@ -70,7 +70,6 @@ const char av_codec_ffversion[] = "FFmpeg version " FFMPEG_VERSION;
volatile int ff_avcodec_locked;
static atomic_int entangled_thread_counter = ATOMIC_VAR_INIT(0);
static AVMutex codec_mutex = AV_MUTEX_INITIALIZER;
-static AVMutex avformat_mutex = AV_MUTEX_INITIALIZER;
void av_fast_padded_malloc(void *ptr, unsigned int *size, size_t min_size)
{
@@ -1904,16 +1903,6 @@ int ff_unlock_avcodec(const AVCodec *codec)
return 0;
}
-int avpriv_lock_avformat(void)
-{
- return ff_mutex_lock(&avformat_mutex) ? -1 : 0;
-}
-
-int avpriv_unlock_avformat(void)
-{
- return ff_mutex_unlock(&avformat_mutex) ? -1 : 0;
-}
-
unsigned int avpriv_toupper4(unsigned int x)
{
return av_toupper(x & 0xFF) +