diff options
author | Anton Khirnov <anton@khirnov.net> | 2011-06-18 17:26:40 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2011-06-18 17:42:44 +0200 |
commit | 84bd2b4bf5ca544e29c48634ac8b2899c58b0d9d (patch) | |
tree | f0a7334c9ef678811d8451fc1d45e1ccc5b63c72 | |
parent | ed63f527f28d1d73589a9e0bac3aed2197f14887 (diff) | |
download | ffmpeg-84bd2b4bf5ca544e29c48634ac8b2899c58b0d9d.tar.gz |
lavf: add a forgotten NULL check in convert_format_parameters().
-rw-r--r-- | libavformat/utils.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c index e3485e6ffa..81bc9b70c3 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -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); |