[FFmpeg-devel] [PATCH] avcodec/hevc_parser: use avpriv_find_start_code in hevc_split()

Reimar Döffinger Reimar.Doeffinger at gmx.de
Mon Mar 9 21:49:04 CET 2015


On Tue, Mar 10, 2015 at 12:57:57AM +0800, zhaoxiu.zeng wrote:
> 在 2015/3/8 20:14, Michael Niedermayer 写道:
> > On Sat, Mar 07, 2015 at 11:47:08PM +0800, zhaoxiu.zeng wrote:
> >> From ab12e3081ba987c2e05d819be97cde96952f1c2a Mon Sep 17 00:00:00 2001
> >> From: Zeng Zhaoxiu <zhaoxiu.zeng at gmail.com>
> >> Date: Sat, 7 Mar 2015 23:29:46 +0800
> >> Subject: [PATCH 1/1] avcodec/hevc_parser: use avpriv_find_start_code in
> >>  hevc_split()
> >>
> >> Signed-off-by: Zeng Zhaoxiu <zhaoxiu.zeng at gmail.com>
> >> ---
> >>  libavcodec/hevc_parser.c | 26 +++++++++++++-------------
> >>  1 file changed, 13 insertions(+), 13 deletions(-)
> >>
> >> diff --git a/libavcodec/hevc_parser.c b/libavcodec/hevc_parser.c
> >> index a6fdbb7..91fc0d4 100644
> >> --- a/libavcodec/hevc_parser.c
> >> +++ b/libavcodec/hevc_parser.c
> >> @@ -286,21 +286,21 @@ static int hevc_parse(AVCodecParserContext *s,
> >>  // Split after the parameter sets at the beginning of the stream if they exist.
> >>  static int hevc_split(AVCodecContext *avctx, const uint8_t *buf, int buf_size)
> >>  {
> >> -    int i;
> >> +    const uint8_t *ptr = buf, end = buf + buf_size;
> > 
> > end is a uint8_t, that will not work
> > also please make sure to test the code you change
> > 
> 
> Sorry for my carelessness. (I tested with "make fate" only)

What would be needed so that this will be tested by "make fate"?
At least from my side contributions to tests are highly appreciated.


More information about the ffmpeg-devel mailing list