diff options
author | James Almer <jamrial@gmail.com> | 2017-03-22 21:27:30 +0300 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2017-03-23 17:44:58 +0300 |
commit | 005da88c1ee231eddd9924ad8173aeeab6366165 (patch) | |
tree | 2ccf866b5c1c921ff4922cd400a0904a05cca297 /libavcodec/mediacodecdec_common.h | |
parent | 4f727fbc7330e726d003e2961fa676ddaf86f994 (diff) |
avcodec/mediacodec: convert to stdatomic
Reviewed-by: wm4 <nfxjfg@googlemail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavcodec/mediacodecdec_common.h')
-rw-r--r-- | libavcodec/mediacodecdec_common.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libavcodec/mediacodecdec_common.h b/libavcodec/mediacodecdec_common.h index c00c2e89f3..10f38277b5 100644 --- a/libavcodec/mediacodecdec_common.h +++ b/libavcodec/mediacodecdec_common.h @@ -24,6 +24,7 @@ #define AVCODEC_MEDIACODECDEC_COMMON_H #include <stdint.h> +#include <stdatomic.h> #include <sys/types.h> #include "libavutil/frame.h" @@ -34,7 +35,7 @@ typedef struct MediaCodecDecContext { - volatile int refcount; + atomic_int refcount; char *codec_name; @@ -88,7 +89,7 @@ typedef struct MediaCodecBuffer { MediaCodecDecContext *ctx; ssize_t index; int64_t pts; - volatile int released; + atomic_int released; } MediaCodecBuffer; |