vp9_parser: handle zero-sized packets.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
pull/48/merge
Ronald S. Bultje 11 years ago committed by Michael Niedermayer
parent 0e15a344c1
commit 9695fb2622
  1. 7
      libavcodec/vp9_parser.c

@ -45,6 +45,13 @@ static int parse(AVCodecParserContext *ctx,
VP9ParseContext *s = ctx->priv_data;
int marker;
if (size <= 0) {
*out_size = 0;
*out_data = data;
return 0;
}
if (s->n_frames > 0) {
*out_data = data;
*out_size = s->size[--s->n_frames];

Loading…
Cancel
Save