lavc/ffwavesynth: fix dependency sizeof(AVFrame).
ffprobe: check av_frame_alloc() failure.
lavc/utils: check av_frame_alloc() failure.
lavc/diracdec: check av_frame_alloc() failure.
lavc/libopenjpegenc: check av_frame_alloc() failure.
lavc/mjpegenc: check av_frame_alloc() failure.
lavc/mjpegenc: use proper error codes.
compat: provide va_copy for old gcc versions.

Since we have this compat/va_copy.h header already we might just as well make
use of it for more than one compiler.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
configure: check that pthreads is compatible with compiler.

In particular the mutex initialization for example won't actually
compile with e.g. gcc 2.95.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
af_aresample: remove only use of array compound literals with non-const initializers in FFmpeg.

Some older compilers might have particular trouble with them,
and they do not really seem worth it to me.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
Merge remote-tracking branch 'cigaes/master'

* cigaes/master:
  lavc/mjpegenc: use proper error codes.
  lavc/mjpegenc: check av_frame_alloc() failure.
  lavc/libopenjpegenc: check av_frame_alloc() failure.
  lavc/diracdec: check av_frame_alloc() failure.
  lavc/utils: check av_frame_alloc() failure.
  ffprobe: check av_frame_alloc() failure.
  lavc/ffwavesynth: fix dependency sizeof(AVFrame).

Merged-by: Michael Niedermayer <michaelni@gmx.at>
avcodec/lagarith: reenable buggy lag_decode_zero_run_line()

This is to prevent regressions in case the old code was able to partly
decode frames (no way to say without a testcase)
Add a memset to prevent use of uninitialized memory until we have a
testcase and can test/fix it

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avcodec/lagarith: use init_get_bits8()

Suggested-by: Reimar
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avcodec/lagarith: check and propagate return value from init_get_bits8()

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avformat/mpegts: demux timed ID3 metadata

Used in some HLS streams ("Timed Metadata for HTTP Live Streaming").

This is just ID3 tags at arbitrary stream positions, but I still added
"timed" to the codec name to avoid confusion with regular non-stream ID3
tags.

Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
avformat/id3v2: parse ID3 Private frames as extra metadata

They are used in HLS.

Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
avformat/http: allow the caller to select a request range

Add AVOptions for setting the initial offset and the ending offset, so
they can be used for setting an appropriate Range header.

Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
avformat/id3v2: allow ID3 parsing without AVFormatContext

Add ff_id3v2_read_dict() for parsing without AVFormatContext, but
instead with AVIOContext and AVDictionary.

AVFormatContext is still used for logging, if available.

Chapter parsing is the only non-logging functionality that actually
needs AVFormatContext, and AFAICS it should be modified to write the
data to ID3v2ExtraMeta first, from where it can be implanted to
AVFormatContext by a separate function (like it is done with
read_apic() and ff_id3v2_parse_apic()). That is outside the scope of
this patch, though.

Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Avoid using empty macro arguments.

These are not supported by all compilers (gcc 2.95 but also older SPARC
compilers, see gcc bug #33304 for example), and there is no real need for them.
One use of this feature remains in libavdevice/v4l2.c which can't be
replaced quite as easily.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
avformat: dont run update_initial_duration() twice

This should avoid floods of first_dts not matching debug messages

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>