Browse Source

lavf: add a forgotten NULL check in convert_format_parameters().

tags/n0.8
Anton Khirnov 14 years ago
parent
commit
84bd2b4bf5
1 changed files with 3 additions and 0 deletions
  1. +3
    -0
      libavformat/utils.c

+ 3
- 0
libavformat/utils.c View File

@@ -395,6 +395,9 @@ static AVDictionary *convert_format_parameters(AVFormatParameters *ap)
char buf[1024];
AVDictionary *opts = NULL;

if (!ap)
return NULL;

if (ap->time_base.num) {
snprintf(buf, sizeof(buf), "%d/%d", ap->time_base.den, ap->time_base.num);
av_dict_set(&opts, "framerate", buf, 0);


Loading…
Cancel
Save