diff options
author | James Almer <jamrial@gmail.com> | 2017-07-19 07:53:22 +0300 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2017-07-21 18:18:10 +0300 |
commit | 7c9d2ad45f4e46ad2c3b2e93051efbe1e0d0529e (patch) | |
tree | 8e09f06e0aacaaeab767a406766d53e79b8acd1a /libavcodec/dca.h | |
parent | 99c5ac20397ec1814d6a50bed74cadd421ad8b9d (diff) |
avcodec/dca: remove GetBitContext usage from avpriv_dca_parse_core_frame_header()
This prevents potential ABI issues with GetBitContext.
Reviewed-by: foo86 <foobaz86@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavcodec/dca.h')
-rw-r--r-- | libavcodec/dca.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/libavcodec/dca.h b/libavcodec/dca.h index cf6204e554..172c965b3b 100644 --- a/libavcodec/dca.h +++ b/libavcodec/dca.h @@ -45,7 +45,8 @@ enum DCAParseError { DCA_PARSE_ERROR_SAMPLE_RATE = -6, DCA_PARSE_ERROR_RESERVED_BIT = -7, DCA_PARSE_ERROR_LFE_FLAG = -8, - DCA_PARSE_ERROR_PCM_RES = -9 + DCA_PARSE_ERROR_PCM_RES = -9, + DCA_PARSE_ERROR_INVALIDDATA = -10, }; typedef struct DCACoreFrameHeader { @@ -212,6 +213,8 @@ int avpriv_dca_convert_bitstream(const uint8_t *src, int src_size, uint8_t *dst, * Parse and validate core frame header * @return 0 on success, negative DCA_PARSE_ERROR_ code on failure */ -int avpriv_dca_parse_core_frame_header(GetBitContext *gb, DCACoreFrameHeader *h); +int avpriv_dca_parse_core_frame_header(DCACoreFrameHeader *h, uint8_t *buf, int size); + +int ff_dca_parse_core_frame_header(DCACoreFrameHeader *h, GetBitContext *gb); #endif /* AVCODEC_DCA_H */ |