diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2006-03-11 00:22:21 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2006-03-11 00:22:21 +0000 |
commit | c04c3282b4334ff64cfd69d40fea010602e830fd (patch) | |
tree | b07e0f447e3146669703bf86229925a44ebd628e /libavformat/utils.c | |
parent | e7c8206e5c4ee83eccb487583331fb39ba73a136 (diff) | |
download | ffmpeg-c04c3282b4334ff64cfd69d40fea010602e830fd.tar.gz |
simplify AVFormatParameters NULL checks
Originally committed as revision 5146 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/utils.c')
-rw-r--r-- | libavformat/utils.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c index 10c3a4a560..15a4a5e09b 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -465,6 +465,12 @@ int av_open_input_stream(AVFormatContext **ic_ptr, { int err; AVFormatContext *ic; + AVFormatParameters default_ap; + + if(!ap){ + ap=&default_ap; + memset(ap, 0, sizeof(default_ap)); + } ic = av_alloc_format_context(); if (!ic) { |